Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make integration tests more reliable #1153

Merged
merged 1 commit into from
Apr 13, 2024
Merged

Conversation

yan12125
Copy link
Contributor

From time to time, some integration tests fail with connection errors. Tests are made more reliable by retrying upon connection failures.

Closes: #1141

From time to time, some integration tests fail with connection errors.
Tests are made more reliable by retrying upon connection failures.

Closes: #1141
@yan12125 yan12125 requested a review from a team as a code owner April 12, 2024 12:20
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I HATE vault and ssl certs. Yes I know I wrote large portions of its hvac implementation but I still hate them for their complexity.

This is beautiful code! But I wonder if there are other places that this redundancy might be added to hvac? Should we be more proactive in building requests.Session()'s in other places?

Honestly though nice code.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! To be honest, I do not have a high level picture about how requests is used in hvac. Maybe more experienced contributors can have a comment.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have had plans to incorporate retries into the hvac adapter system so that a library user does not need to create a custom session, but it was going to be after making some big changes to the adapter system which have been on hold:

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sessions and certs are hard. This is a great addition.

@briantist briantist self-assigned this Apr 12, 2024
@briantist briantist added patch Used as part of release-drafter's version-resolver configuration tests related to tests (not necessarily CI/CD) labels Apr 12, 2024
@briantist briantist added this to the 2.2.0 milestone Apr 12, 2024
@briantist briantist merged commit 6778d4d into hvac:main Apr 13, 2024
35 checks passed
@briantist briantist added the misc Used as a release-drafter "category" label Apr 13, 2024
@yan12125 yan12125 deleted the test-reliability branch April 14, 2024 05:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
misc Used as a release-drafter "category" patch Used as part of release-drafter's version-resolver configuration tests related to tests (not necessarily CI/CD)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Some tests in test_health.py are flaky
3 participants