You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tuscany.apache.org by rf...@apache.org on 2009/06/10 18:02:09 UTC

svn commit: r783408 - in /tuscany/java/sca/itest/nodes: one-node-test/src/test/java/itest/OneNodeTestCase.java two-nodes-test/src/test/java/itest/TwoNodesTestCase.java

Author: rfeng
Date: Wed Jun 10 16:02:08 2009
New Revision: 783408

URL: http://svn.apache.org/viewvc?rev=783408&view=rev
Log:
Change the file separator

Modified:
    tuscany/java/sca/itest/nodes/one-node-test/src/test/java/itest/OneNodeTestCase.java
    tuscany/java/sca/itest/nodes/two-nodes-test/src/test/java/itest/TwoNodesTestCase.java

Modified: tuscany/java/sca/itest/nodes/one-node-test/src/test/java/itest/OneNodeTestCase.java
URL: http://svn.apache.org/viewvc/tuscany/java/sca/itest/nodes/one-node-test/src/test/java/itest/OneNodeTestCase.java?rev=783408&r1=783407&r2=783408&view=diff
==============================================================================
--- tuscany/java/sca/itest/nodes/one-node-test/src/test/java/itest/OneNodeTestCase.java (original)
+++ tuscany/java/sca/itest/nodes/one-node-test/src/test/java/itest/OneNodeTestCase.java Wed Jun 10 16:02:08 2009
@@ -6,15 +6,15 @@
  * 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.
  */
 
 package itest;
@@ -42,20 +42,20 @@
         System.setProperty("org.apache.tuscany.sca.contribution.processor.ValidationSchemaExtensionPoint.enabled", "false");
         NodeFactory factory = NodeFactory.newInstance();
         node = factory.createNode(
-               new Contribution("service", "..\\helloworld-service\\target\\itest-nodes-helloworld-service-2.0-SNAPSHOT.jar"),
-               new Contribution("client", "..\\helloworld-client\\target\\itest-nodes-helloworld-client-2.0-SNAPSHOT.jar"));
+               new Contribution("service", "../helloworld-service/target/itest-nodes-helloworld-service-2.0-SNAPSHOT.jar"),
+               new Contribution("client", "../helloworld-client/target/itest-nodes-helloworld-client-2.0-SNAPSHOT.jar"));
         node.start();
     }
 
     @Test
     public void testCalculator() throws Exception {
-        
+
         // Ideally this would use the SCAClient API but leaving that tillwe have the basics working
-        
+
         Helloworld service = node.getService(Helloworld.class, "HelloworldService");
         assertNotNull(service);
         assertEquals("Hello Petra", service.sayHello("Petra"));
-        
+
         Helloworld client = node.getService(Helloworld.class, "HelloworldClient");
         assertNotNull(client);
         assertEquals("Hi Hello Petra", client.sayHello("Petra"));

Modified: tuscany/java/sca/itest/nodes/two-nodes-test/src/test/java/itest/TwoNodesTestCase.java
URL: http://svn.apache.org/viewvc/tuscany/java/sca/itest/nodes/two-nodes-test/src/test/java/itest/TwoNodesTestCase.java?rev=783408&r1=783407&r2=783408&view=diff
==============================================================================
--- tuscany/java/sca/itest/nodes/two-nodes-test/src/test/java/itest/TwoNodesTestCase.java (original)
+++ tuscany/java/sca/itest/nodes/two-nodes-test/src/test/java/itest/TwoNodesTestCase.java Wed Jun 10 16:02:08 2009
@@ -6,15 +6,15 @@
  * 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.
  */
 
 package itest;
@@ -23,6 +23,8 @@
 import static org.junit.Assert.assertNotNull;
 import itest.nodes.Helloworld;
 
+import java.io.File;
+
 import org.apache.tuscany.sca.node.Contribution;
 import org.apache.tuscany.sca.node.Node;
 import org.apache.tuscany.sca.node.NodeFactory;
@@ -44,9 +46,9 @@
     public static void setUpBeforeClass() throws Exception {
         System.setProperty("org.apache.tuscany.sca.contribution.processor.ValidationSchemaExtensionPoint.enabled", "false");
         NodeFactory factory = NodeFactory.newInstance();
-        serviceNode = factory.createNode(new Contribution("service", "..\\helloworld-service\\target\\itest-nodes-helloworld-service-2.0-SNAPSHOT.jar"));
+        serviceNode = factory.createNode(new Contribution("service", new File("../helloworld-service/target/itest-nodes-helloworld-service-2.0-SNAPSHOT.jar").toURI().toString()));
         serviceNode.start();
-        clientNode = factory.createNode(new Contribution("client", "..\\helloworld-client\\target\\itest-nodes-helloworld-client-2.0-SNAPSHOT.jar"));
+        clientNode = factory.createNode(new Contribution("client", new File("../helloworld-client/target/itest-nodes-helloworld-client-2.0-SNAPSHOT.jar").toURI().toString()));
         clientNode.start();
     }
 
@@ -55,7 +57,7 @@
         Helloworld service = serviceNode.getService(Helloworld.class, "HelloworldService");
         assertNotNull(service);
         assertEquals("Hello Petra", service.sayHello("Petra"));
-        
+
         Helloworld client = clientNode.getService(Helloworld.class, "HelloworldClient");
         assertNotNull(client);
         assertEquals("Hi Hello Petra", client.sayHello("Petra"));
@@ -67,7 +69,7 @@
         Helloworld service = scaClient.getService(Helloworld.class, "HelloworldService", null);
         assertNotNull(service);
         assertEquals("Hello Petra", service.sayHello("Petra"));
-        
+
         Helloworld client = scaClient.getService(Helloworld.class, "HelloworldClient", null);
         assertNotNull(client);
         assertEquals("Hi Hello Petra", client.sayHello("Petra"));