diff options
5 files changed, 18 insertions, 46 deletions
diff --git a/java/sca/itest/nodes/two-nodes-two-vms-test/client-config.xml b/java/sca/itest/nodes/two-nodes-two-vms-test/client-config.xml index 174ddbd6ab..1bda0ee4b7 100644 --- a/java/sca/itest/nodes/two-nodes-two-vms-test/client-config.xml +++ b/java/sca/itest/nodes/two-nodes-two-vms-test/client-config.xml @@ -29,8 +29,8 @@ <binding name="sca:binding.ws" baseURIs="http://localhost:8082/ws https://localhost:8082/ws"/> <!-- Configure a list of contributions --> - <contribution uri="iface" location="file:../helloworld-iface/target/itest-nodes-helloworld-iface-2.0-SNAPSHOT.jar"/> - <contribution uri="client" location="file:../helloworld-client/target/itest-nodes-helloworld-client-2.0-SNAPSHOT.jar"> + <contribution uri="iface" location="../helloworld-iface/target/itest-nodes-helloworld-iface-2.0-SNAPSHOT.jar"/> + <contribution uri="client" location="../helloworld-client/target/itest-nodes-helloworld-client-2.0-SNAPSHOT.jar"> <!-- doesn't pick up the deployable composite properly without this?--> <deploymentComposite location="helloworld-client.composite"/> </contribution> diff --git a/java/sca/itest/nodes/two-nodes-two-vms-test/client.xml b/java/sca/itest/nodes/two-nodes-two-vms-test/client.xml index 82b1b01525..bb65805144 100644 --- a/java/sca/itest/nodes/two-nodes-two-vms-test/client.xml +++ b/java/sca/itest/nodes/two-nodes-two-vms-test/client.xml @@ -6,27 +6,27 @@ * to you under the Apache License, Version 2.0 (the * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY * KIND, either express or implied. See the License for the * specific language governing permissions and limitations - * under the License. + * under the License. --> <project name="server" default="run"> <!--echo>${runtime_classpath}</echo--> - + <target name="run"> <java classpath="${runtime_classpath}" classname="org.apache.tuscany.sca.node.launcher.NodeMain" fork="true"> <!--jvmarg value="-Djava.util.logging.config.file=../logging.properties"/--> <arg value="-ttl"/> <arg value="0"/> <arg value="-node"/> - <arg value="file:./client-config.xml"/> + <arg value="./client-config.xml"/> </java> </target> diff --git a/java/sca/itest/nodes/two-nodes-two-vms-test/server-config.xml b/java/sca/itest/nodes/two-nodes-two-vms-test/server-config.xml index af8a0c0e49..14a48f507a 100644 --- a/java/sca/itest/nodes/two-nodes-two-vms-test/server-config.xml +++ b/java/sca/itest/nodes/two-nodes-two-vms-test/server-config.xml @@ -29,8 +29,8 @@ <binding name="sca:binding.ws" baseURIs="http://localhost:8082/ws https://localhost:8082/ws"/> <!-- Configure a list of contributions --> - <contribution uri="iface" location="file:../helloworld-iface/target/itest-nodes-helloworld-iface-2.0-SNAPSHOT.jar"/> - <contribution uri="service" location="file:../helloworld-service/target/itest-nodes-helloworld-service-2.0-SNAPSHOT.jar"> + <contribution uri="iface" location="../helloworld-iface/target/classes"/> + <contribution uri="service" location="../helloworld-service/target/classes"> <!-- doesn't pick up the deployable composite properly without this?--> <deploymentComposite location="helloworld-service.composite"/> </contribution> diff --git a/java/sca/itest/nodes/two-nodes-two-vms-test/server.xml b/java/sca/itest/nodes/two-nodes-two-vms-test/server.xml index 7ff376565d..7b6d206b7f 100644 --- a/java/sca/itest/nodes/two-nodes-two-vms-test/server.xml +++ b/java/sca/itest/nodes/two-nodes-two-vms-test/server.xml @@ -6,27 +6,27 @@ * to you under the Apache License, Version 2.0 (the * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY * KIND, either express or implied. See the License for the * specific language governing permissions and limitations - * under the License. + * under the License. --> <project name="server" default="run"> <!--echo>${runtime_classpath}</echo--> - + <target name="run"> <java classpath="${runtime_classpath}" classname="org.apache.tuscany.sca.node.launcher.NodeMain" fork="true"> <!--jvmarg value="-Djava.util.logging.config.file=../logging.properties"/--> <!--arg value="-ttl"/> <arg value="0"/--> <arg value="-node"/> - <arg value="file:./server-config.xml"/> + <arg value="./server-config.xml"/> </java> </target> diff --git a/java/sca/itest/nodes/two-nodes-two-vms-test/src/test/java/itest/TwoNodesTestCase.java b/java/sca/itest/nodes/two-nodes-two-vms-test/src/test/java/itest/TwoNodesTestCase.java index 6f0c7565e7..b27d16a562 100644 --- a/java/sca/itest/nodes/two-nodes-two-vms-test/src/test/java/itest/TwoNodesTestCase.java +++ b/java/sca/itest/nodes/two-nodes-two-vms-test/src/test/java/itest/TwoNodesTestCase.java @@ -19,67 +19,39 @@ package itest; -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertNotNull; -import itest.nodes.Helloworld; - import java.io.File; -import java.net.URL; -import org.apache.tuscany.sca.node.Contribution; import org.apache.tuscany.sca.node.Node; import org.apache.tuscany.sca.node.NodeFactory; import org.junit.AfterClass; import org.junit.BeforeClass; import org.junit.Test; -import org.oasisopen.sca.client.SCAClient; -import org.oasisopen.sca.client.SCAClientFactory; /** * This shows how to test the Calculator service component. */ -public class TwoNodesTestCase{ +public class TwoNodesTestCase { private static Node serviceNode; - private static Node clientNode; @BeforeClass public static void setUpBeforeClass() throws Exception { NodeFactory factory = NodeFactory.newInstance(); - serviceNode = factory.createNode(new URL("file:./server-config.xml")); + serviceNode = factory.createNode(new File("server-config.xml").toURI().toURL()); serviceNode.start(); - - //clientNode = factory.createNode(new Contribution("client", getJar("../helloworld-client/target"))); - //clientNode.start(); - } - /** - * Get the jar in the target folder without being dependent on the version name to - * make tuscany releases easier - */ - private static String getJar(String targetDirectory) { - File f = new File(targetDirectory); - for (File file : f.listFiles()) { - if (file.getName().endsWith(".jar")) { - return file.toURI().toString(); - } - } - throw new IllegalStateException("Can't find jar in: " + targetDirectory); } - + @Test public void testNothing() throws Exception { - } + } @AfterClass public static void tearDownAfterClass() throws Exception { if (serviceNode != null) { serviceNode.stop(); } - if (clientNode != null) { - clientNode.stop(); - } } } |