This is an automated email from the ASF dual-hosted git repository. gnodet pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/camel.git
commit 14bcb256f2dd85859eb6a168e685e5250e17fae0 Author: Guillaume Nodet <gno...@gmail.com> AuthorDate: Thu Jun 11 17:27:41 2020 +0200 [CAMEL-11807] Upgrade camel-master to junit5 --- components/camel-master/pom.xml | 2 +- .../apache/camel/component/master/EndpointUriEncodingTest.java | 4 ++-- .../org/apache/camel/component/master/MasterComponentTest.java | 10 ++++++---- 3 files changed, 9 insertions(+), 7 deletions(-) diff --git a/components/camel-master/pom.xml b/components/camel-master/pom.xml index 5e20fbd..0d40600 100644 --- a/components/camel-master/pom.xml +++ b/components/camel-master/pom.xml @@ -49,7 +49,7 @@ <!-- test dependencies --> <dependency> <groupId>org.apache.camel</groupId> - <artifactId>camel-test</artifactId> + <artifactId>camel-test-junit5</artifactId> <scope>test</scope> </dependency> diff --git a/components/camel-master/src/test/java/org/apache/camel/component/master/EndpointUriEncodingTest.java b/components/camel-master/src/test/java/org/apache/camel/component/master/EndpointUriEncodingTest.java index 1c46091..b07f1ad 100644 --- a/components/camel-master/src/test/java/org/apache/camel/component/master/EndpointUriEncodingTest.java +++ b/components/camel-master/src/test/java/org/apache/camel/component/master/EndpointUriEncodingTest.java @@ -29,8 +29,8 @@ import org.apache.camel.component.mock.MockEndpoint; import org.apache.camel.support.DefaultComponent; import org.apache.camel.support.DefaultConsumer; import org.apache.camel.support.DefaultEndpoint; -import org.apache.camel.test.junit4.CamelTestSupport; -import org.junit.Test; +import org.apache.camel.test.junit5.CamelTestSupport; +import org.junit.jupiter.api.Test; public class EndpointUriEncodingTest extends CamelTestSupport { diff --git a/components/camel-master/src/test/java/org/apache/camel/component/master/MasterComponentTest.java b/components/camel-master/src/test/java/org/apache/camel/component/master/MasterComponentTest.java index 560b6d6..6dc33de 100644 --- a/components/camel-master/src/test/java/org/apache/camel/component/master/MasterComponentTest.java +++ b/components/camel-master/src/test/java/org/apache/camel/component/master/MasterComponentTest.java @@ -29,11 +29,13 @@ import java.util.stream.IntStream; import org.apache.camel.builder.RouteBuilder; import org.apache.camel.component.file.cluster.FileLockClusterService; import org.apache.camel.impl.DefaultCamelContext; -import org.junit.Assert; -import org.junit.Test; +import org.junit.jupiter.api.Test; import org.slf4j.Logger; import org.slf4j.LoggerFactory; +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertTrue; + public class MasterComponentTest { private static final Logger LOGGER = LoggerFactory.getLogger(MasterComponentTest.class); private static final List<String> INSTANCES = IntStream.range(0, 3).mapToObj(Integer::toString).collect(Collectors.toList()); @@ -50,8 +52,8 @@ public class MasterComponentTest { LATCH.await(1, TimeUnit.MINUTES); SCHEDULER.shutdownNow(); - Assert.assertEquals(INSTANCES.size(), RESULTS.size()); - Assert.assertTrue(RESULTS.containsAll(INSTANCES)); + assertEquals(INSTANCES.size(), RESULTS.size()); + assertTrue(RESULTS.containsAll(INSTANCES)); } // ************************************