Skip to content

Additional Testcontainers 2.0.x recipes#832

Merged
timtebeek merged 8 commits intoopenrewrite:mainfrom
eddumelendez:tc-2.0
Oct 17, 2025
Merged

Additional Testcontainers 2.0.x recipes#832
timtebeek merged 8 commits intoopenrewrite:mainfrom
eddumelendez:tc-2.0

Conversation

@eddumelendez
Copy link
Copy Markdown
Contributor

  • Recipes for new container classes
  • Recipes for new testcontainers modules
  • Recipe to apply changes in Testcontainers 2.0

@github-project-automation github-project-automation bot moved this to In Progress in OpenRewrite Oct 16, 2025
@eddumelendez eddumelendez changed the title tc 2.0 Recipes for Testcontainers 2.0.x Oct 16, 2025
@eddumelendez
Copy link
Copy Markdown
Contributor Author

will Neo4jContainer<?> neo4j = Neo4jContainer<>("neo4j:4") be replaced by Neo4jContainer neo4j = Neo4jContainer("neo4j:4")?

@jkschneider
Copy link
Copy Markdown
Member

will Neo4jContainer<?> neo4j = Neo4jContainer<>("neo4j:4") be replaced by Neo4jContainer neo4j = Neo4jContainer("neo4j:4")?

If you mean will ChangeType drop the generic automatically, then no. I would suggest a custom recipe for this.

@timtebeek timtebeek self-requested a review October 17, 2025 10:59
@timtebeek timtebeek changed the title Recipes for Testcontainers 2.0.x Additional Testcontainers 2.0.x recipes Oct 17, 2025
@timtebeek
Copy link
Copy Markdown
Member

I've resolved the conflicts with #830 and made sure we'll bump both Maven and Gradle dependencies to any 2.x version going forward. Indeed dropping the generic type arguments isn't yet supported, but I think there's value in merging these steps already, and follow up separately for any such wildcards. Would you want to start a draft for that @eddumelendez ?

@timtebeek timtebeek merged commit 42c3046 into openrewrite:main Oct 17, 2025
@github-project-automation github-project-automation bot moved this from In Progress to Done in OpenRewrite Oct 17, 2025
@eddumelendez eddumelendez deleted the tc-2.0 branch October 17, 2025 11:18
@eddumelendez
Copy link
Copy Markdown
Contributor Author

Hi, thanks! I will!

mergify bot added a commit to robfrank/linklift that referenced this pull request Oct 30, 2025
…rom 3.19.0 to 3.20.0 [skip ci]

Bumps [org.openrewrite.recipe:rewrite-testing-frameworks](https://github.com/openrewrite/rewrite-testing-frameworks) from 3.19.0 to 3.20.0.
Release notes

*Sourced from [org.openrewrite.recipe:rewrite-testing-frameworks's releases](https://github.com/openrewrite/rewrite-testing-frameworks/releases).*

> 3.20.0
> ------
>
> What's Changed
> --------------
>
> * Change dependencies and types for testcontainers v2 by [`@​sullis`](https://github.com/sullis) in [openrewrite/rewrite-testing-frameworks#830](https://redirect.github.com/openrewrite/rewrite-testing-frameworks/pull/830)
> * Additional Testcontainers 2.0.x recipes by [`@​eddumelendez`](https://github.com/eddumelendez) in [openrewrite/rewrite-testing-frameworks#832](https://redirect.github.com/openrewrite/rewrite-testing-frameworks/pull/832)
> * Upgrade testcontainers for the JUnit 5 migration by [`@​timtebeek`](https://github.com/timtebeek) in [openrewrite/rewrite-testing-frameworks#833](https://redirect.github.com/openrewrite/rewrite-testing-frameworks/pull/833)
>
> New Contributors
> ----------------
>
> * [`@​eddumelendez`](https://github.com/eddumelendez) made their first contribution in [openrewrite/rewrite-testing-frameworks#832](https://redirect.github.com/openrewrite/rewrite-testing-frameworks/pull/832)
>
> **Full Changelog**: <openrewrite/rewrite-testing-frameworks@v3.19.0...v3.20.0>


Commits

* [`1a882f4`](openrewrite/rewrite-testing-frameworks@1a882f4) Upgrade testcontainers for the JUnit 5 migration ([#833](https://redirect.github.com/openrewrite/rewrite-testing-frameworks/issues/833))
* [`be5cbb3`](openrewrite/rewrite-testing-frameworks@be5cbb3) Fix failing easymock tests
* [`f1a3fa5`](openrewrite/rewrite-testing-frameworks@f1a3fa5) Fix failing easymock tests
* [`42c3046`](openrewrite/rewrite-testing-frameworks@42c3046) Additional Testcontainers 2.0.x recipes ([#832](https://redirect.github.com/openrewrite/rewrite-testing-frameworks/issues/832))
* [`8c1afc3`](openrewrite/rewrite-testing-frameworks@8c1afc3) Use classpathFromResources for `EasyMockToMockitoTest` which needs JUnit-4
* [`d7fe158`](openrewrite/rewrite-testing-frameworks@d7fe158) Change dependencies and types for testcontainers v2 ([#830](https://redirect.github.com/openrewrite/rewrite-testing-frameworks/issues/830))
* [`ba3685d`](openrewrite/rewrite-testing-frameworks@ba3685d) Avoid Jackson 2.19 brought in through test dependencies
* See full diff in [compare view](openrewrite/rewrite-testing-frameworks@v3.19.0...v3.20.0)
  
[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility\_score?dependency-name=org.openrewrite.recipe:rewrite-testing-frameworks&package-manager=maven&previous-version=3.19.0&new-version=3.20.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`.
[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)
---
Dependabot commands and options
  
You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `@dependabot show  ignore conditions` will show all of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

3 participants