Removing deprecated DMAAP library
[policy/drools-pdp.git] / feature-pooling-messages / src / test / java / org / onap / policy / drools / pooling / state / InactiveStateTest.java
@@ -3,7 +3,7 @@
  * ONAP
  * ================================================================================
  * Copyright (C) 2018, 2020 AT&T Intellectual Property. All rights reserved.
- * Modifications Copyright (C) 2020 Nordix Foundation
+ * Modifications Copyright (C) 2020, 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.
@@ -21,8 +21,8 @@
 
 package org.onap.policy.drools.pooling.state;
 
-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;
 import static org.mockito.ArgumentMatchers.any;
 import static org.mockito.Mockito.mock;
 import static org.mockito.Mockito.never;
@@ -30,14 +30,14 @@ import static org.mockito.Mockito.verify;
 import static org.mockito.Mockito.when;
 
 import org.apache.commons.lang3.tuple.Pair;
-import org.junit.Before;
-import org.junit.Test;
+import org.junit.jupiter.api.BeforeEach;
+import org.junit.jupiter.api.Test;
 import org.onap.policy.drools.pooling.message.BucketAssignments;
 import org.onap.policy.drools.pooling.message.Identification;
 import org.onap.policy.drools.pooling.message.Leader;
 import org.onap.policy.drools.pooling.message.Query;
 
-public class InactiveStateTest extends SupportBasicStateTester {
+class InactiveStateTest extends SupportBasicStateTester {
 
     private InactiveState state;
 
@@ -46,7 +46,7 @@ public class InactiveStateTest extends SupportBasicStateTester {
      *
      */
     @Override
-    @Before
+    @BeforeEach
     public void setUp() throws Exception {
         super.setUp();
 
@@ -54,7 +54,7 @@ public class InactiveStateTest extends SupportBasicStateTester {
     }
 
     @Test
-    public void testProcessLeader() {
+    void testProcessLeader() {
         State next = mock(State.class);
         when(mgr.goActive()).thenReturn(next);
 
@@ -67,7 +67,7 @@ public class InactiveStateTest extends SupportBasicStateTester {
     }
 
     @Test
-    public void testProcessLeader_Invalid() {
+    void testProcessLeader_Invalid() {
         Leader msg = new Leader(PREV_HOST, null);
 
         // should stay in the same state, and not start distributing
@@ -78,7 +78,7 @@ public class InactiveStateTest extends SupportBasicStateTester {
     }
 
     @Test
-    public void testProcessQuery() {
+    void testProcessQuery() {
         State next = mock(State.class);
         when(mgr.goQuery()).thenReturn(next);
 
@@ -90,12 +90,12 @@ public class InactiveStateTest extends SupportBasicStateTester {
     }
 
     @Test
-    public void testGoInatcive() {
+    void testGoInatcive() {
         assertNull(state.goInactive());
     }
 
     @Test
-    public void testStart() {
+    void testStart() {
         state.start();
 
         Pair<Long, StateTimerTask> timer = onceTasks.remove();
@@ -110,7 +110,7 @@ public class InactiveStateTest extends SupportBasicStateTester {
     }
 
     @Test
-    public void testInactiveState() {
+    void testInactiveState() {
         /*
          * Prove the state is attached to the manager by invoking getHost(), which
          * delegates to the manager.