aboutsummaryrefslogtreecommitdiffstats
path: root/examples/examples-acm/src/test/java
diff options
context:
space:
mode:
authoradheli.tavares <adheli.tavares@est.tech>2024-06-18 10:39:27 +0100
committeradheli.tavares <adheli.tavares@est.tech>2024-06-18 10:45:14 +0100
commitc7d878cb8b0cf3146646674ad4bd6cabe6716f46 (patch)
tree427e29277cb2e77d5a63ae05bda5c7da163812e3 /examples/examples-acm/src/test/java
parente9b746340711ddfccee7ac0f669ace626b1b3d46 (diff)
Convert junit4 to junit5
- examples module Issue-ID: POLICY-5041 Change-Id: Ia46a6590149571d31dde918e1ea77753ab330f90 Signed-off-by: adheli.tavares <adheli.tavares@est.tech>
Diffstat (limited to 'examples/examples-acm/src/test/java')
-rw-r--r--examples/examples-acm/src/test/java/org/onap/policy/apex/examples/acm/TestApexAcmExample.java10
1 files changed, 5 insertions, 5 deletions
diff --git a/examples/examples-acm/src/test/java/org/onap/policy/apex/examples/acm/TestApexAcmExample.java b/examples/examples-acm/src/test/java/org/onap/policy/apex/examples/acm/TestApexAcmExample.java
index 9df25e678..be4bec096 100644
--- a/examples/examples-acm/src/test/java/org/onap/policy/apex/examples/acm/TestApexAcmExample.java
+++ b/examples/examples-acm/src/test/java/org/onap/policy/apex/examples/acm/TestApexAcmExample.java
@@ -1,6 +1,6 @@
/*-
* ============LICENSE_START=======================================================
- * Copyright (C) 2022-2023 Nordix Foundation.
+ * Copyright (C) 2022-2024 Nordix Foundation.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -24,7 +24,7 @@ import static org.awaitility.Awaitility.await;
import jakarta.ws.rs.client.ClientBuilder;
import java.util.concurrent.TimeUnit;
-import org.junit.Test;
+import org.junit.jupiter.api.Test;
import org.onap.policy.apex.auth.clieditor.tosca.ApexCliToscaEditorMain;
import org.onap.policy.apex.service.engine.main.ApexMain;
@@ -32,10 +32,10 @@ import org.onap.policy.apex.service.engine.main.ApexMain;
* Test class to run an example policy for ACM interaction. Event received on
* message topic (dummy REST Endpoint here) and triggers a new message.
*/
-public class TestApexAcmExample {
+class TestApexAcmExample {
@Test
- public void testExample() {
+ void testExample() {
try (var dmmap = new AcmTestServerDmaap()) {
dmmap.validate();
@@ -68,7 +68,7 @@ public class TestApexAcmExample {
final var client = ClientBuilder.newClient();
final var apexMain = new ApexMain(apexArgs);
- await().atMost(5000, TimeUnit.MILLISECONDS).until(() -> apexMain.isAlive());
+ await().atMost(5000, TimeUnit.MILLISECONDS).until(apexMain::isAlive);
String getLoggedEventUrl = "http://localhost:3904/events/getLoggedEvent";
await().atMost(20000, TimeUnit.MILLISECONDS).until(() -> {