diff options
author | Michael Arrastia <MArrasti@amdocs.com> | 2018-11-28 17:27:31 +0000 |
---|---|---|
committer | Michael Arrastia <MArrasti@amdocs.com> | 2018-11-28 17:27:31 +0000 |
commit | d894ec51a86cfb4d711d3c053d8aa46759584456 (patch) | |
tree | c60a1680d735c5c76bc1e9ec625be6140d4b7667 /src/test/java/org/onap/aai/spike/schema/GraphEventTransformerTest.java | |
parent | 9eb82afe62f6891d1e140fd9003e1ceb7df119ee (diff) |
Upgrade version of aai-common
* Configure Spike with schema ingestion beans.
* Update OXMModelLoader and EdgeRulesLoader to make use of schema
ingestion beans. Here there is an acknowledged awkward marrying of
bean creation and static method use.
* Update tests to mock schema ingestion beans and organise test
resources.
Change-Id: I1f043aa5852dbd2737a804ebc282a12afb9fb39f
Issue-ID: AAI-1951
Signed-off-by: Michael Arrastia <MArrasti@amdocs.com>
Diffstat (limited to 'src/test/java/org/onap/aai/spike/schema/GraphEventTransformerTest.java')
-rw-r--r-- | src/test/java/org/onap/aai/spike/schema/GraphEventTransformerTest.java | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/test/java/org/onap/aai/spike/schema/GraphEventTransformerTest.java b/src/test/java/org/onap/aai/spike/schema/GraphEventTransformerTest.java index 1e14e5e..32ebc9b 100644 --- a/src/test/java/org/onap/aai/spike/schema/GraphEventTransformerTest.java +++ b/src/test/java/org/onap/aai/spike/schema/GraphEventTransformerTest.java @@ -30,6 +30,9 @@ import java.io.IOException; import java.net.URISyntaxException; import org.junit.Before; import org.junit.Test; +import org.junit.runner.RunWith; +import org.mockito.junit.MockitoJUnitRunner; +import org.onap.aai.spike.OXMModelLoaderSetup; import org.onap.aai.spike.event.envelope.EventEnvelopeParser; import org.onap.aai.spike.event.incoming.GizmoGraphEvent; import org.onap.aai.spike.exception.SpikeException; @@ -40,21 +43,18 @@ import org.onap.aai.spike.test.util.TestFileReader; * This set of tests validates the ability of the {@link GraphEventTransformer} to produce OXM model * compliant representations of generic graph entities. */ -public class GraphEventTransformerTest { +@RunWith(MockitoJUnitRunner.Silent.class) +public class GraphEventTransformerTest extends OXMModelLoaderSetup { + /** * Performs all setup steps expected to be performed prior to each test. */ @Before public void setup() throws Exception { - // Load the OXM model definitions. OXMModelLoader.loadModels(); - - // Load the relationship definitions. - System.setProperty("CONFIG_HOME", "src/test/resources/"); EdgeRulesLoader.loadModels(); } - /** * Validates that, given a raw vertex from the graph abstraction layer, we can transform it into a * JSON string which corresponds to the OXM model. @@ -119,7 +119,7 @@ public class GraphEventTransformerTest { } } } - + @Test public void TestValidateFieldType() throws SpikeException { String value = null; |