diff options
Diffstat (limited to 'src/test/java')
5 files changed, 20 insertions, 15 deletions
diff --git a/src/test/java/org/onap/aai/datarouter/policy/EntityEventPolicyTest.java b/src/test/java/org/onap/aai/datarouter/policy/EntityEventPolicyTest.java index b76e7ee..aa9b4fa 100644 --- a/src/test/java/org/onap/aai/datarouter/policy/EntityEventPolicyTest.java +++ b/src/test/java/org/onap/aai/datarouter/policy/EntityEventPolicyTest.java @@ -34,6 +34,7 @@ import org.apache.commons.io.IOUtils; import org.junit.Before; import org.junit.Test; import org.junit.runner.RunWith; +import org.onap.aai.datarouter.Application; import org.onap.aai.datarouter.util.NodeUtils; import org.onap.aai.setup.SchemaLocationsBean; import org.onap.aai.setup.SchemaVersions; @@ -44,7 +45,7 @@ import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; @RunWith(SpringJUnit4ClassRunner.class) -@ContextConfiguration("file:src/test/resources/spring-beans/data-router-oxm.xml") +@ContextConfiguration(classes = {Application.class}) public class EntityEventPolicyTest { private EntityEventPolicyConfig eventPolicyConfig; private EntityEventPolicy policy; diff --git a/src/test/java/org/onap/aai/datarouter/policy/SpikeAggregateGenericVnfProcessorTest.java b/src/test/java/org/onap/aai/datarouter/policy/SpikeAggregateGenericVnfProcessorTest.java index cf9f013..8f15751 100644 --- a/src/test/java/org/onap/aai/datarouter/policy/SpikeAggregateGenericVnfProcessorTest.java +++ b/src/test/java/org/onap/aai/datarouter/policy/SpikeAggregateGenericVnfProcessorTest.java @@ -34,6 +34,7 @@ import org.apache.commons.io.IOUtils; import org.junit.Before; import org.junit.Test; import org.junit.runner.RunWith; +import org.onap.aai.datarouter.Application; import org.onap.aai.datarouter.util.NodeUtils; import org.onap.aai.setup.SchemaLocationsBean; import org.onap.aai.setup.SchemaVersions; @@ -43,7 +44,7 @@ import org.springframework.test.context.ContextConfiguration; import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; @RunWith(SpringJUnit4ClassRunner.class) -@ContextConfiguration("file:src/test/resources/spring-beans/data-router-oxm.xml") +@ContextConfiguration(classes = {Application.class}) public class SpikeAggregateGenericVnfProcessorTest { private SpikeEventPolicyConfig eventPolicyConfig; private SpikeAggregateGenericVnfProcessor policy; @@ -53,13 +54,13 @@ public class SpikeAggregateGenericVnfProcessorTest { private SchemaVersions schemaVersions; @Autowired private SchemaLocationsBean schemaLocationsBean; - + @Before public void init() throws Exception { eventPolicyConfig = new SpikeEventPolicyConfig(); eventPolicyConfig.setSearchKeystorePwd("password"); eventPolicyConfig.setSourceDomain("JUNIT"); - + eventPolicyConfig.setSchemaVersions(schemaVersions); eventPolicyConfig.setSchemaLocationsBean(schemaLocationsBean); diff --git a/src/test/java/org/onap/aai/datarouter/policy/SpikeAutosuggestProcessorTest.java b/src/test/java/org/onap/aai/datarouter/policy/SpikeAutosuggestProcessorTest.java index 6791ac3..bbde7e3 100644 --- a/src/test/java/org/onap/aai/datarouter/policy/SpikeAutosuggestProcessorTest.java +++ b/src/test/java/org/onap/aai/datarouter/policy/SpikeAutosuggestProcessorTest.java @@ -34,6 +34,7 @@ import org.apache.commons.io.IOUtils; import org.junit.Before; import org.junit.Test; import org.junit.runner.RunWith; +import org.onap.aai.datarouter.Application; import org.onap.aai.datarouter.util.NodeUtils; import org.onap.aai.setup.SchemaLocationsBean; import org.onap.aai.setup.SchemaVersions; @@ -43,7 +44,7 @@ import org.springframework.test.context.ContextConfiguration; import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; @RunWith(SpringJUnit4ClassRunner.class) -@ContextConfiguration("file:src/test/resources/spring-beans/data-router-oxm.xml") +@ContextConfiguration(classes = {Application.class}) public class SpikeAutosuggestProcessorTest { private SpikeEventPolicyConfig eventPolicyConfig; private SpikeAutosuggestIndexProcessor policy; @@ -53,17 +54,17 @@ public class SpikeAutosuggestProcessorTest { private SchemaVersions schemaVersions; @Autowired private SchemaLocationsBean schemaLocationsBean; - + @Before public void init() throws Exception { - + eventPolicyConfig = new SpikeEventPolicyConfig(); eventPolicyConfig.setSearchKeystorePwd("password"); eventPolicyConfig.setSourceDomain("JUNIT"); - + eventPolicyConfig.setSchemaVersions(schemaVersions); eventPolicyConfig.setSchemaLocationsBean(schemaLocationsBean); - + searchDb = new InMemorySearchDatastore(); policy = new SpikeAutosuggestProcessorStubbed(eventPolicyConfig).withSearchDb(searchDb); diff --git a/src/test/java/org/onap/aai/datarouter/policy/SpikeEntityEventPolicyTest.java b/src/test/java/org/onap/aai/datarouter/policy/SpikeEntityEventPolicyTest.java index b78ba0e..514bd0b 100644 --- a/src/test/java/org/onap/aai/datarouter/policy/SpikeEntityEventPolicyTest.java +++ b/src/test/java/org/onap/aai/datarouter/policy/SpikeEntityEventPolicyTest.java @@ -34,6 +34,7 @@ import org.apache.commons.io.IOUtils; import org.junit.Before; import org.junit.Test; import org.junit.runner.RunWith; +import org.onap.aai.datarouter.Application; import org.onap.aai.datarouter.util.NodeUtils; import org.onap.aai.setup.SchemaLocationsBean; import org.onap.aai.setup.SchemaVersions; @@ -43,24 +44,24 @@ import org.springframework.test.context.ContextConfiguration; import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; @RunWith(SpringJUnit4ClassRunner.class) -@ContextConfiguration("file:src/test/resources/spring-beans/data-router-oxm.xml") +@ContextConfiguration(classes = {Application.class}) public class SpikeEntityEventPolicyTest { private SpikeEntityEventPolicyConfig eventPolicyConfig; private SpikeEntityEventPolicy policy; private InMemorySearchDatastore searchDb; - + @Autowired private SchemaVersions schemaVersions; @Autowired private SchemaLocationsBean schemaLocationsBean; - + @Before public void init() throws Exception { - + eventPolicyConfig = new SpikeEntityEventPolicyConfig(); eventPolicyConfig.setSearchKeystorePwd("password"); eventPolicyConfig.setSourceDomain("JUNIT"); - + eventPolicyConfig.setSchemaVersions(schemaVersions); eventPolicyConfig.setSchemaLocationsBean(schemaLocationsBean); diff --git a/src/test/java/org/onap/aai/datarouter/policy/SpikeEntitySearchProcessorTest.java b/src/test/java/org/onap/aai/datarouter/policy/SpikeEntitySearchProcessorTest.java index 56af3ea..ef9c1db 100644 --- a/src/test/java/org/onap/aai/datarouter/policy/SpikeEntitySearchProcessorTest.java +++ b/src/test/java/org/onap/aai/datarouter/policy/SpikeEntitySearchProcessorTest.java @@ -34,6 +34,7 @@ import org.apache.commons.io.IOUtils; import org.junit.Before; import org.junit.Test; import org.junit.runner.RunWith; +import org.onap.aai.datarouter.Application; import org.onap.aai.datarouter.util.NodeUtils; import org.onap.aai.setup.SchemaLocationsBean; import org.onap.aai.setup.SchemaVersions; @@ -43,7 +44,7 @@ import org.springframework.test.context.ContextConfiguration; import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; @RunWith(SpringJUnit4ClassRunner.class) -@ContextConfiguration("file:src/test/resources/spring-beans/data-router-oxm.xml") +@ContextConfiguration(classes = {Application.class}) public class SpikeEntitySearchProcessorTest { private SpikeEventPolicyConfig eventPolicyConfig; private SpikeEntitySearchProcessor policy; |