Removing deprecated DMAAP library
[policy/drools-pdp.git] / policy-core / src / test / java / org / onap / policy / drools / core / lock / AlwaysFailLockTest.java
index 178ef0a..51273d7 100644 (file)
@@ -3,6 +3,7 @@
  * ONAP
  * ================================================================================
  * Copyright (C) 2021 AT&T Intellectual Property. All rights reserved.
+ * Modifications Copyright (C) 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.
 package org.onap.policy.drools.core.lock;
 
 import static org.assertj.core.api.Assertions.assertThatCode;
-import static org.junit.Assert.assertFalse;
-import static org.junit.Assert.assertTrue;
+import static org.junit.jupiter.api.Assertions.assertFalse;
+import static org.junit.jupiter.api.Assertions.assertTrue;
 import static org.mockito.Mockito.mock;
 
-import org.junit.Before;
-import org.junit.Test;
+import org.junit.jupiter.api.BeforeEach;
+import org.junit.jupiter.api.Test;
 
-public class AlwaysFailLockTest extends AlwaysLockBaseTest<AlwaysFailLock> {
+class AlwaysFailLockTest extends AlwaysLockBaseTest<AlwaysFailLock> {
 
-    @Before
+    @BeforeEach
     public void setUp() {
         callback = mock(LockCallback.class);
         lock = new AlwaysFailLock(RESOURCE, OWNER_KEY, HOLD_SEC, callback);
     }
 
     @Test
-    public void testAlwaysFailLockNoArgs() {
+    void testAlwaysFailLockNoArgs() {
         assertThatCode(AlwaysFailLock::new).doesNotThrowAnyException();
     }
 
     @Test
-    public void testUnavailableLock() {
+    void testUnavailableLock() {
         assertTrue(lock.isUnavailable());
     }
 
     @Test
-    public void testFree() {
+    void testFree() {
         assertFalse(lock.free());
         assertTrue(lock.isUnavailable());
     }