1212import org .apache .kafka .common .errors .SaslAuthenticationException ;
1313import org .apache .kafka .common .errors .TopicAuthorizationException ;
1414import org .awaitility .Awaitility ;
15- import org .junit .Test ;
15+ import org .junit .jupiter . api . Test ;
1616import org .testcontainers .containers .GenericContainer ;
1717import org .testcontainers .containers .Network ;
1818import org .testcontainers .containers .SocatContainer ;
3030import static org .assertj .core .api .Assertions .assertThat ;
3131import static org .assertj .core .api .Assertions .assertThatThrownBy ;
3232
33- public class RedpandaContainerTest extends AbstractRedpanda {
33+ class RedpandaContainerTest extends AbstractRedpanda {
3434
3535 private static final String REDPANDA_IMAGE = "docker.redpanda.com/redpandadata/redpanda:v22.2.1" ;
3636
3737 private static final DockerImageName REDPANDA_DOCKER_IMAGE = DockerImageName .parse (REDPANDA_IMAGE );
3838
3939 @ Test
40- public void testUsage () throws Exception {
40+ void testUsage () throws Exception {
4141 try (RedpandaContainer container = new RedpandaContainer (REDPANDA_DOCKER_IMAGE )) {
4242 container .start ();
4343 testKafkaFunctionality (container .getBootstrapServers ());
4444 }
4545 }
4646
4747 @ Test
48- public void testUsageWithStringImage () throws Exception {
48+ void testUsageWithStringImage () throws Exception {
4949 try (
5050 // constructorWithVersion {
5151 RedpandaContainer container = new RedpandaContainer ("docker.redpanda.com/redpandadata/redpanda:v23.1.2" )
@@ -61,21 +61,21 @@ public void testUsageWithStringImage() throws Exception {
6161 }
6262
6363 @ Test
64- public void testNotCompatibleVersion () {
64+ void testNotCompatibleVersion () {
6565 assertThatThrownBy (() -> new RedpandaContainer ("docker.redpanda.com/redpandadata/redpanda:v21.11.19" ))
6666 .isInstanceOf (IllegalArgumentException .class )
6767 .hasMessageContaining ("Redpanda version must be >= v22.2.1" );
6868 }
6969
7070 @ Test
71- public void redpandadataRedpandaImageVersion2221ShouldNotBeCompatible () {
71+ void redpandadataRedpandaImageVersion2221ShouldNotBeCompatible () {
7272 assertThatThrownBy (() -> new RedpandaContainer ("redpandadata/redpanda:v21.11.19" ))
7373 .isInstanceOf (IllegalArgumentException .class )
7474 .hasMessageContaining ("Redpanda version must be >= v22.2.1" );
7575 }
7676
7777 @ Test
78- public void testSchemaRegistry () {
78+ void testSchemaRegistry () {
7979 try (RedpandaContainer container = new RedpandaContainer (REDPANDA_DOCKER_IMAGE )) {
8080 container .start ();
8181
@@ -105,7 +105,7 @@ public void testSchemaRegistry() {
105105 }
106106
107107 @ Test
108- public void testUsageWithListener () throws Exception {
108+ void testUsageWithListener () throws Exception {
109109 try (
110110 Network network = Network .newNetwork ();
111111 RedpandaContainer redpanda = new RedpandaContainer ("docker.redpanda.com/redpandadata/redpanda:v23.1.7" )
@@ -132,7 +132,7 @@ public void testUsageWithListener() throws Exception {
132132 }
133133
134134 @ Test
135- public void testUsageWithListenerInTheSameNetwork () throws Exception {
135+ void testUsageWithListenerInTheSameNetwork () throws Exception {
136136 try (
137137 Network network = Network .newNetwork ();
138138 // registerListener {
@@ -165,7 +165,7 @@ public void testUsageWithListenerInTheSameNetwork() throws Exception {
165165 }
166166
167167 @ Test
168- public void testUsageWithListenerFromProxy () throws Exception {
168+ void testUsageWithListenerFromProxy () throws Exception {
169169 try (
170170 Network network = Network .newNetwork ();
171171 // createProxy {
@@ -187,7 +187,7 @@ public void testUsageWithListenerFromProxy() throws Exception {
187187 }
188188
189189 @ Test
190- public void testUsageWithListenerAndSasl () throws Exception {
190+ void testUsageWithListenerAndSasl () throws Exception {
191191 final String username = "panda" ;
192192 final String password = "pandapass" ;
193193 final String algorithm = "SCRAM-SHA-256" ;
@@ -266,7 +266,7 @@ public void testUsageWithListenerAndSasl() throws Exception {
266266
267267 @ SneakyThrows
268268 @ Test
269- public void enableSaslWithSuccessfulTopicCreation () {
269+ void enableSaslWithSuccessfulTopicCreation () {
270270 try (
271271 // security {
272272 RedpandaContainer redpanda = new RedpandaContainer ("docker.redpanda.com/redpandadata/redpanda:v23.1.7" )
@@ -289,7 +289,7 @@ public void enableSaslWithSuccessfulTopicCreation() {
289289 }
290290
291291 @ Test
292- public void enableSaslWithUnsuccessfulTopicCreation () {
292+ void enableSaslWithUnsuccessfulTopicCreation () {
293293 try (
294294 RedpandaContainer redpanda = new RedpandaContainer ("docker.redpanda.com/redpandadata/redpanda:v23.1.7" )
295295 .enableAuthorization ()
@@ -313,7 +313,7 @@ public void enableSaslWithUnsuccessfulTopicCreation() {
313313 }
314314
315315 @ Test
316- public void enableSaslAndWithAuthenticationError () {
316+ void enableSaslAndWithAuthenticationError () {
317317 try (
318318 RedpandaContainer redpanda = new RedpandaContainer ("docker.redpanda.com/redpandadata/redpanda:v23.1.7" )
319319 .enableAuthorization ()
@@ -335,7 +335,7 @@ public void enableSaslAndWithAuthenticationError() {
335335 }
336336
337337 @ Test
338- public void schemaRegistryWithHttpBasic () {
338+ void schemaRegistryWithHttpBasic () {
339339 try (
340340 RedpandaContainer redpanda = new RedpandaContainer ("docker.redpanda.com/redpandadata/redpanda:v23.1.7" )
341341 .enableSchemaRegistryHttpBasicAuth ()
@@ -362,7 +362,7 @@ public void schemaRegistryWithHttpBasic() {
362362
363363 @ SneakyThrows
364364 @ Test
365- public void testRestProxy () {
365+ void testRestProxy () {
366366 try (RedpandaContainer redpanda = new RedpandaContainer ("docker.redpanda.com/redpandadata/redpanda:v23.1.7" )) {
367367 redpanda .start ();
368368
0 commit comments