diff options
author | liamfallon <liam.fallon@ericsson.com> | 2018-09-19 17:23:48 +0100 |
---|---|---|
committer | liamfallon <liam.fallon@ericsson.com> | 2018-09-20 12:26:57 +0100 |
commit | aece3940d349329efe6d220961f6f2a487f90565 (patch) | |
tree | a55e5302c038a130327cc5e69aee78aab1eb3ac8 /testsuites/integration/integration-executor-test/src/test/java | |
parent | f28256b49d1041a959646536d16094fc68431b12 (diff) |
Refactor Editor REST servlet
Issue-ID: POLICY-1034
Change-Id: Ifa08c7a31b4fe19eb62c2035b67b6f5cad313b5f
Signed-off-by: liamfallon <liam.fallon@ericsson.com>
Diffstat (limited to 'testsuites/integration/integration-executor-test/src/test/java')
4 files changed, 12 insertions, 4 deletions
diff --git a/testsuites/integration/integration-executor-test/src/test/java/org/onap/policy/apex/testsuites/integration/executor/engine/TestApexEngineJava.java b/testsuites/integration/integration-executor-test/src/test/java/org/onap/policy/apex/testsuites/integration/executor/engine/TestApexEngineJava.java index b551a061e..bfdd08255 100644 --- a/testsuites/integration/integration-executor-test/src/test/java/org/onap/policy/apex/testsuites/integration/executor/engine/TestApexEngineJava.java +++ b/testsuites/integration/integration-executor-test/src/test/java/org/onap/policy/apex/testsuites/integration/executor/engine/TestApexEngineJava.java @@ -30,6 +30,7 @@ import org.onap.policy.apex.context.parameters.ContextParameterConstants; import org.onap.policy.apex.context.parameters.ContextParameters; import org.onap.policy.apex.context.parameters.SchemaParameters; import org.onap.policy.apex.core.engine.EngineParameters; +import org.onap.policy.apex.core.infrastructure.threading.ThreadUtilities; import org.onap.policy.apex.model.basicmodel.concepts.ApexException; import org.onap.policy.apex.plugins.executor.java.JavaExecutorParameters; import org.onap.policy.common.parameters.ParameterService; @@ -98,6 +99,7 @@ public class TestApexEngineJava { @Test public void testApexEngineJava() throws InterruptedException, IOException, ApexException { new TestApexEngine("JAVA", engineParameters); + ThreadUtilities.sleep(5000); new TestApexEngine("JAVA", engineParameters); } } diff --git a/testsuites/integration/integration-executor-test/src/test/java/org/onap/policy/apex/testsuites/integration/executor/engine/TestApexEngineJavascript.java b/testsuites/integration/integration-executor-test/src/test/java/org/onap/policy/apex/testsuites/integration/executor/engine/TestApexEngineJavascript.java index 51e39cfe1..05068fcb0 100644 --- a/testsuites/integration/integration-executor-test/src/test/java/org/onap/policy/apex/testsuites/integration/executor/engine/TestApexEngineJavascript.java +++ b/testsuites/integration/integration-executor-test/src/test/java/org/onap/policy/apex/testsuites/integration/executor/engine/TestApexEngineJavascript.java @@ -30,6 +30,7 @@ import org.onap.policy.apex.context.parameters.ContextParameterConstants; import org.onap.policy.apex.context.parameters.ContextParameters; import org.onap.policy.apex.context.parameters.SchemaParameters; import org.onap.policy.apex.core.engine.EngineParameters; +import org.onap.policy.apex.core.infrastructure.threading.ThreadUtilities; import org.onap.policy.apex.model.basicmodel.concepts.ApexException; import org.onap.policy.apex.plugins.executor.javascript.JavascriptExecutorParameters; import org.onap.policy.common.parameters.ParameterService; @@ -97,6 +98,7 @@ public class TestApexEngineJavascript { public void testApexEngineJavascript() throws ApexException, InterruptedException, IOException { new TestApexEngine("JAVASCRIPT", engineParameters); + ThreadUtilities.sleep(5000); new TestApexEngine("JAVASCRIPT", engineParameters); } } diff --git a/testsuites/integration/integration-executor-test/src/test/java/org/onap/policy/apex/testsuites/integration/executor/engine/TestApexEngineJython.java b/testsuites/integration/integration-executor-test/src/test/java/org/onap/policy/apex/testsuites/integration/executor/engine/TestApexEngineJython.java index 163a60d20..12a28e293 100644 --- a/testsuites/integration/integration-executor-test/src/test/java/org/onap/policy/apex/testsuites/integration/executor/engine/TestApexEngineJython.java +++ b/testsuites/integration/integration-executor-test/src/test/java/org/onap/policy/apex/testsuites/integration/executor/engine/TestApexEngineJython.java @@ -30,6 +30,7 @@ import org.onap.policy.apex.context.parameters.ContextParameterConstants; import org.onap.policy.apex.context.parameters.ContextParameters; import org.onap.policy.apex.context.parameters.SchemaParameters; import org.onap.policy.apex.core.engine.EngineParameters; +import org.onap.policy.apex.core.infrastructure.threading.ThreadUtilities; import org.onap.policy.apex.model.basicmodel.concepts.ApexException; import org.onap.policy.apex.plugins.executor.jython.JythonExecutorParameters; import org.onap.policy.common.parameters.ParameterService; @@ -96,6 +97,7 @@ public class TestApexEngineJython { @Test public void testApexEngineJython() throws ApexException, InterruptedException, IOException { new TestApexEngine("JYTHON", engineParameters); + ThreadUtilities.sleep(5000); new TestApexEngine("JYTHON", engineParameters); } } diff --git a/testsuites/integration/integration-executor-test/src/test/java/org/onap/policy/apex/testsuites/integration/executor/engine/TestApexEngineMvel.java b/testsuites/integration/integration-executor-test/src/test/java/org/onap/policy/apex/testsuites/integration/executor/engine/TestApexEngineMvel.java index 604105a03..7b4d05a5f 100644 --- a/testsuites/integration/integration-executor-test/src/test/java/org/onap/policy/apex/testsuites/integration/executor/engine/TestApexEngineMvel.java +++ b/testsuites/integration/integration-executor-test/src/test/java/org/onap/policy/apex/testsuites/integration/executor/engine/TestApexEngineMvel.java @@ -30,6 +30,7 @@ import org.onap.policy.apex.context.parameters.ContextParameterConstants; import org.onap.policy.apex.context.parameters.ContextParameters; import org.onap.policy.apex.context.parameters.SchemaParameters; import org.onap.policy.apex.core.engine.EngineParameters; +import org.onap.policy.apex.core.infrastructure.threading.ThreadUtilities; import org.onap.policy.apex.model.basicmodel.concepts.ApexException; import org.onap.policy.apex.plugins.executor.mvel.MvelExecutorParameters; import org.onap.policy.common.parameters.ParameterService; @@ -48,12 +49,12 @@ public class TestApexEngineMvel { @Before public void beforeTest() { schemaParameters = new SchemaParameters(); - + schemaParameters.setName(ContextParameterConstants.SCHEMA_GROUP_NAME); schemaParameters.getSchemaHelperParameterMap().put("JAVA", new JavaSchemaHelperParameters()); ParameterService.register(schemaParameters); - + contextParameters = new ContextParameters(); contextParameters.setName(ContextParameterConstants.MAIN_GROUP_NAME); @@ -65,7 +66,7 @@ public class TestApexEngineMvel { ParameterService.register(contextParameters.getDistributorParameters()); ParameterService.register(contextParameters.getLockManagerParameters()); ParameterService.register(contextParameters.getPersistorParameters()); - + engineParameters = new EngineParameters(); engineParameters.getExecutorParameterMap().put("MVEL", new MvelExecutorParameters()); ParameterService.register(engineParameters); @@ -77,7 +78,7 @@ public class TestApexEngineMvel { @After public void afterTest() { ParameterService.deregister(engineParameters); - + ParameterService.deregister(contextParameters.getDistributorParameters()); ParameterService.deregister(contextParameters.getLockManagerParameters()); ParameterService.deregister(contextParameters.getPersistorParameters()); @@ -96,6 +97,7 @@ public class TestApexEngineMvel { @Test public void testApexEngineMvel() throws ApexException, InterruptedException, IOException { new TestApexEngine("MVEL", engineParameters); + ThreadUtilities.sleep(5000); new TestApexEngine("MVEL", engineParameters); } } |