diff options
author | Bjørn Christian Seime <bjorncs@yahooinc.com> | 2022-07-27 16:37:12 +0200 |
---|---|---|
committer | Bjørn Christian Seime <bjorncs@yahooinc.com> | 2022-07-28 14:51:33 +0200 |
commit | a407f4643fb1ad34499d1662eab166a83d75abe8 (patch) | |
tree | 41022109ea511391fe50fae5ed14feac5e819a23 | |
parent | cecd77aabe2fd389803f92d1cfbaa5b93eabdf86 (diff) |
Convert zookeeper-client-commons to junit5
-rw-r--r-- | zookeeper-client-common/pom.xml | 9 | ||||
-rw-r--r-- | zookeeper-client-common/src/test/java/com/yahoo/vespa/zookeeper/client/ZkClientConfigBuilderTest.java | 10 |
2 files changed, 12 insertions, 7 deletions
diff --git a/zookeeper-client-common/pom.xml b/zookeeper-client-common/pom.xml index 5eafd040e79..c3dc4629702 100644 --- a/zookeeper-client-common/pom.xml +++ b/zookeeper-client-common/pom.xml @@ -40,8 +40,13 @@ <!-- compile scope --> <!-- test scope --> <dependency> - <groupId>junit</groupId> - <artifactId>junit</artifactId> + <groupId>org.junit.jupiter</groupId> + <artifactId>junit-jupiter-api</artifactId> + <scope>test</scope> + </dependency> + <dependency> + <groupId>org.junit.jupiter</groupId> + <artifactId>junit-jupiter-engine</artifactId> <scope>test</scope> </dependency> </dependencies> diff --git a/zookeeper-client-common/src/test/java/com/yahoo/vespa/zookeeper/client/ZkClientConfigBuilderTest.java b/zookeeper-client-common/src/test/java/com/yahoo/vespa/zookeeper/client/ZkClientConfigBuilderTest.java index 7ffce79b67a..6248424d8da 100644 --- a/zookeeper-client-common/src/test/java/com/yahoo/vespa/zookeeper/client/ZkClientConfigBuilderTest.java +++ b/zookeeper-client-common/src/test/java/com/yahoo/vespa/zookeeper/client/ZkClientConfigBuilderTest.java @@ -3,7 +3,7 @@ package com.yahoo.vespa.zookeeper.client; import com.yahoo.security.tls.TlsContext; import org.apache.zookeeper.client.ZKClientConfig; -import org.junit.Test; +import org.junit.jupiter.api.Test; import javax.net.ssl.SSLContext; import javax.net.ssl.SSLEngine; @@ -17,8 +17,8 @@ import static com.yahoo.vespa.zookeeper.client.ZkClientConfigBuilder.SSL_CLIENTA import static com.yahoo.vespa.zookeeper.client.ZkClientConfigBuilder.SSL_CONTEXT_SUPPLIER_CLASS_PROPERTY; import static com.yahoo.vespa.zookeeper.client.ZkClientConfigBuilder.SSL_ENABLED_CIPHERSUITES_PROPERTY; import static com.yahoo.vespa.zookeeper.client.ZkClientConfigBuilder.SSL_ENABLED_PROTOCOLS_PROPERTY; -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertNull; +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertNull; /** * Tests the zookeeper client config builder. @@ -26,7 +26,7 @@ import static org.junit.Assert.assertNull; public class ZkClientConfigBuilderTest { @Test - public void config_when_not_using_tls_context() { + void config_when_not_using_tls_context() { ZkClientConfigBuilder builder = new ZkClientConfigBuilder(null); ZKClientConfig config = builder.toConfig(); assertEquals("false", config.getProperty(CLIENT_SECURE_PROPERTY)); @@ -36,7 +36,7 @@ public class ZkClientConfigBuilderTest { } @Test - public void config_when_using_system_tls_context() { + void config_when_using_system_tls_context() { ZkClientConfigBuilder builder = new ZkClientConfigBuilder(new MockTlsContext()); ZKClientConfig config = builder.toConfig(); assertEquals("true", config.getProperty(CLIENT_SECURE_PROPERTY)); |