summaryrefslogtreecommitdiffstats
path: root/sca-java-2.x/trunk/modules/domain-node/src/test/java/org/apache/tuscany/sca/runtime/TwoNodesTestCase.java
diff options
context:
space:
mode:
authorantelder <antelder@13f79535-47bb-0310-9956-ffa450edef68>2011-05-18 12:00:54 +0000
committerantelder <antelder@13f79535-47bb-0310-9956-ffa450edef68>2011-05-18 12:00:54 +0000
commit12d682d6fe8632db6149c894dc3d77ec6f3163e6 (patch)
tree8cec5fad0776fe97885eb9a15cc18b98ca6709d1 /sca-java-2.x/trunk/modules/domain-node/src/test/java/org/apache/tuscany/sca/runtime/TwoNodesTestCase.java
parent8703d6e9b35f6139ba89525bd3bb15bd9039f3ac (diff)
Fix Hazelcast reg to properly remove entries when things are removed and update tests so properly shutdown the runtime after each test
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@1124209 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'sca-java-2.x/trunk/modules/domain-node/src/test/java/org/apache/tuscany/sca/runtime/TwoNodesTestCase.java')
-rw-r--r--sca-java-2.x/trunk/modules/domain-node/src/test/java/org/apache/tuscany/sca/runtime/TwoNodesTestCase.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/sca-java-2.x/trunk/modules/domain-node/src/test/java/org/apache/tuscany/sca/runtime/TwoNodesTestCase.java b/sca-java-2.x/trunk/modules/domain-node/src/test/java/org/apache/tuscany/sca/runtime/TwoNodesTestCase.java
index 4de9215838..0b71b68d70 100644
--- a/sca-java-2.x/trunk/modules/domain-node/src/test/java/org/apache/tuscany/sca/runtime/TwoNodesTestCase.java
+++ b/sca-java-2.x/trunk/modules/domain-node/src/test/java/org/apache/tuscany/sca/runtime/TwoNodesTestCase.java
@@ -34,7 +34,9 @@ public class TwoNodesTestCase {
@Test
public void testInstallDeployable() throws NoSuchServiceException, NoSuchDomainException, ContributionReadException, ActivationException, ValidationException {
- Node node1 = TuscanyRuntime.newInstance().createNode("uri:TwoNodesTestCase?multicast=off&bind=127.0.0.1:44331");
+ TuscanyRuntime runtime = TuscanyRuntime.newInstance();
+ try {
+ Node node1 = runtime.createNode("uri:TwoNodesTestCase?multicast=off&bind=127.0.0.1:44331");
node1.installContribution("helloworld", "src/test/resources/sample-helloworld.jar", null, null);
node1.startComposite("helloworld", "helloworld.composite");
@@ -42,6 +44,7 @@ public class TwoNodesTestCase {
Helloworld helloworldService = node2.getService(Helloworld.class, "HelloworldComponent");
Assert.assertEquals("Hello petra", helloworldService.sayHello("petra"));
+ } finally { runtime.stop(); }
}
}