File tree Expand file tree Collapse file tree 1 file changed +27
-0
lines changed
src/main/resources/META-INF/rewrite Expand file tree Collapse file tree 1 file changed +27
-0
lines changed Original file line number Diff line number Diff line change @@ -4617,6 +4617,33 @@ examples:
46174617 language: java
46184618 ---
46194619type : specs.openrewrite.org/v1beta/example
4620+ recipeName : org.openrewrite.java.testing.testcontainers.AddTestcontainersAnnotations
4621+ examples :
4622+ - description : ' `AddTestcontainersAnnotationsTest#convertsSingleGenericContainerRule`'
4623+ sources :
4624+ - before : |
4625+ import org.junit.Rule;
4626+ import org.junit.Test;
4627+ import org.testcontainers.containers.GenericContainer;
4628+
4629+ class MyTest {
4630+ @Rule
4631+ public GenericContainer<?> myContainer = new GenericContainer<>("redis:latest");
4632+ }
4633+ after: |
4634+ import org.junit.Test;
4635+ import org.testcontainers.containers.GenericContainer;
4636+ import org.testcontainers.junit.jupiter.Container;
4637+ import org.testcontainers.junit.jupiter.Testcontainers;
4638+
4639+ @Testcontainers
4640+ class MyTest {
4641+ @Container
4642+ public GenericContainer<?> myContainer = new GenericContainer<>("redis:latest");
4643+ }
4644+ language: java
4645+ ---
4646+ type : specs.openrewrite.org/v1beta/example
46204647recipeName : org.openrewrite.java.testing.testcontainers.ExplicitContainerImage
46214648examples :
46224649- description : ' `ExplicitContainerImageTest#explicitContainerImage`'
You can’t perform that action at this time.
0 commit comments