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

chore(build): update testcontainers dependency #1376

Merged
merged 1 commit into from
Feb 14, 2024
Merged

Conversation

0xERR0R
Copy link
Owner

@0xERR0R 0xERR0R commented Feb 13, 2024

This PR updates all testcontainers dependencies to v0.27.0. This should close 4 dependabot PRs

In the version v0.27.0 the network creation was changed:

  • testcontainers.GenericNetwork and testcontainers.NetworkRequest used in helper.go are deprecated, I added linter exclusion here
  • I have tried to rewrite the code and use network.New() as suggested by testcontainers team, but this breaks current logic with testNetwork in helper.go: It is not possible to pass the network name, new API always generates new unique name, see feat: create networks with random names testcontainers/testcontainers-go#1993
  • I think, we can leave the deprecated code for now, but we need to rework the network creation in e2e (maybe to create one network on test start (before suite) and use it for all tests?)

@0xERR0R 0xERR0R requested a review from kwitsch February 13, 2024 21:41
@0xERR0R 0xERR0R added this to the v0.24 milestone Feb 13, 2024
@kwitsch
Copy link
Collaborator

kwitsch commented Feb 13, 2024

That looks promising.
Most of our current logic regarding the e2e-networks exists to combat problems with the old implementation.
I skimmed over the merge and it looks like we could discard much of it. 👍
I'll try changing the tests to the new methods. 😊

Copy link
Collaborator

@kwitsch kwitsch left a comment

Choose a reason for hiding this comment

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

I'll refactor the e2e-networks in a follow up PR.

@0xERR0R 0xERR0R merged commit 716ad94 into main Feb 14, 2024
17 checks passed
@delete-merged-branch delete-merged-branch bot deleted the update-testcontainers branch February 14, 2024 07:20
@mdelapenya
Copy link

Hey team, please let us know if we can be of any help, but it feels you are already doing a great job keeping up with the changes 🙇

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants