From 0bf9442b6ce2b79ef7b8d4b4dee9d3d9c9de6013 Mon Sep 17 00:00:00 2001 From: kuldipr Date: Fri, 2 Oct 2020 12:25:58 -0400 Subject: Fixed test case failues found as part of AAI-3100 testing but not due to AAI-3100 fix Issue-ID: AAI-3100 Signed-off-by: kuldipr Change-Id: Icb50543e29c31ade5a367213b40b7a74f3c91661 --- aai-core/src/test/java/org/onap/aai/audit/ListEndpointsTest.java | 3 ++- .../test/java/org/onap/aai/introspection/sideeffect/DataCopyTest.java | 4 +++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/aai-core/src/test/java/org/onap/aai/audit/ListEndpointsTest.java b/aai-core/src/test/java/org/onap/aai/audit/ListEndpointsTest.java index eafffe63..f476a7cc 100644 --- a/aai-core/src/test/java/org/onap/aai/audit/ListEndpointsTest.java +++ b/aai-core/src/test/java/org/onap/aai/audit/ListEndpointsTest.java @@ -24,6 +24,7 @@ import org.junit.Assert; import org.junit.Before; import org.junit.BeforeClass; import org.junit.Test; +import org.springframework.test.annotation.DirtiesContext; import org.junit.rules.ExpectedException; import org.onap.aai.AAISetup; import org.onap.aai.concurrent.AaiCallable; @@ -47,7 +48,7 @@ import java.util.Map; import java.util.Properties; import static org.junit.Assert.assertTrue; - +@DirtiesContext(classMode = DirtiesContext.ClassMode.BEFORE_CLASS) public class ListEndpointsTest extends AAISetup { private Properties properties; diff --git a/aai-core/src/test/java/org/onap/aai/introspection/sideeffect/DataCopyTest.java b/aai-core/src/test/java/org/onap/aai/introspection/sideeffect/DataCopyTest.java index 7dadb14a..bd7e87a7 100644 --- a/aai-core/src/test/java/org/onap/aai/introspection/sideeffect/DataCopyTest.java +++ b/aai-core/src/test/java/org/onap/aai/introspection/sideeffect/DataCopyTest.java @@ -33,6 +33,8 @@ import org.junit.runner.RunWith; import org.junit.runners.Parameterized; import org.mockito.Mock; import org.mockito.MockitoAnnotations; +import org.springframework.test.annotation.DirtiesContext; + import org.onap.aai.AAISetup; import org.onap.aai.db.props.AAIProperties; import org.onap.aai.edges.enums.EdgeProperty; @@ -60,7 +62,7 @@ import static org.mockito.Mockito.spy; import static org.mockito.Mockito.when; @RunWith(value = Parameterized.class) - +@DirtiesContext(classMode = DirtiesContext.ClassMode.BEFORE_CLASS) public class DataCopyTest extends AAISetup { private static JanusGraph graph; -- cgit 1.2.3-korg