tuscany-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kwilli...@apache.org
Subject svn commit: r652798 - in /incubator/tuscany/java/sca/vtest/java-api/conversation/id/src: main/java/org/apache/tuscany/sca/vtest/javaapi/conversation/id/ main/java/org/apache/tuscany/sca/vtest/javaapi/conversation/id/impl/ test/java/org/apache/tuscany/s...
Date Fri, 02 May 2008 16:14:45 GMT
Author: kwilliams
Date: Fri May  2 09:14:45 2008
New Revision: 652798

URL: http://svn.apache.org/viewvc?rev=652798&view=rev
Log:
More conversation id tests

Modified:
    incubator/tuscany/java/sca/vtest/java-api/conversation/id/src/main/java/org/apache/tuscany/sca/vtest/javaapi/conversation/id/AService.java
    incubator/tuscany/java/sca/vtest/java-api/conversation/id/src/main/java/org/apache/tuscany/sca/vtest/javaapi/conversation/id/impl/AServiceImpl.java
    incubator/tuscany/java/sca/vtest/java-api/conversation/id/src/test/java/org/apache/tuscany/sca/vtest/javaapi/conversation/id/ConversationIDTestCase.java

Modified: incubator/tuscany/java/sca/vtest/java-api/conversation/id/src/main/java/org/apache/tuscany/sca/vtest/javaapi/conversation/id/AService.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/vtest/java-api/conversation/id/src/main/java/org/apache/tuscany/sca/vtest/javaapi/conversation/id/AService.java?rev=652798&r1=652797&r2=652798&view=diff
==============================================================================
--- incubator/tuscany/java/sca/vtest/java-api/conversation/id/src/main/java/org/apache/tuscany/sca/vtest/javaapi/conversation/id/AService.java
(original)
+++ incubator/tuscany/java/sca/vtest/java-api/conversation/id/src/main/java/org/apache/tuscany/sca/vtest/javaapi/conversation/id/AService.java
Fri May  2 09:14:45 2008
@@ -34,4 +34,6 @@
 
     public void testAnnotation4();
 
+    public void testAnnotation5();
+
 }

Modified: incubator/tuscany/java/sca/vtest/java-api/conversation/id/src/main/java/org/apache/tuscany/sca/vtest/javaapi/conversation/id/impl/AServiceImpl.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/vtest/java-api/conversation/id/src/main/java/org/apache/tuscany/sca/vtest/javaapi/conversation/id/impl/AServiceImpl.java?rev=652798&r1=652797&r2=652798&view=diff
==============================================================================
--- incubator/tuscany/java/sca/vtest/java-api/conversation/id/src/main/java/org/apache/tuscany/sca/vtest/javaapi/conversation/id/impl/AServiceImpl.java
(original)
+++ incubator/tuscany/java/sca/vtest/java-api/conversation/id/src/main/java/org/apache/tuscany/sca/vtest/javaapi/conversation/id/impl/AServiceImpl.java
Fri May  2 09:14:45 2008
@@ -23,6 +23,7 @@
 import org.apache.tuscany.sca.vtest.javaapi.conversation.id.BService;
 import org.apache.tuscany.sca.vtest.javaapi.conversation.id.CService;
 import org.apache.tuscany.sca.vtest.javaapi.conversation.id.CustomConversationId;
+import org.junit.Assert;
 import org.osoa.sca.ServiceReference;
 import org.osoa.sca.annotations.Reference;
 import org.osoa.sca.annotations.Scope;
@@ -55,4 +56,14 @@
         c.setConversationID(id);
         c.getService().testAnnotation();        
     }
+
+    public void testAnnotation5() {
+        b.getService().getState();
+        Assert.assertNotNull(b.getConversation().getConversationID());
+//        Assert.assertNotNull(b.getConversationID());  
+        
+        CustomConversationId id = new CustomConversationId (1, "One");
+        c.setConversationID(id);
+        Assert.assertSame(id, c.getConversationID());
+    }
 }

Modified: incubator/tuscany/java/sca/vtest/java-api/conversation/id/src/test/java/org/apache/tuscany/sca/vtest/javaapi/conversation/id/ConversationIDTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/vtest/java-api/conversation/id/src/test/java/org/apache/tuscany/sca/vtest/javaapi/conversation/id/ConversationIDTestCase.java?rev=652798&r1=652797&r2=652798&view=diff
==============================================================================
--- incubator/tuscany/java/sca/vtest/java-api/conversation/id/src/test/java/org/apache/tuscany/sca/vtest/javaapi/conversation/id/ConversationIDTestCase.java
(original)
+++ incubator/tuscany/java/sca/vtest/java-api/conversation/id/src/test/java/org/apache/tuscany/sca/vtest/javaapi/conversation/id/ConversationIDTestCase.java
Fri May  2 09:14:45 2008
@@ -90,10 +90,31 @@
      * <p>
      * ... but application generated conversation IDs may be other complex
      * types.
+     * <p>
+     * Lines 513, 514
+     * <p>
+     * ... To do this, the client would not use reference injection, but would
+     * use the of ServiceReference.setConversationID() API.
      */
     @Test
     public void idAnnotation4() throws Exception {
         aService.testAnnotation4();
     }
 
+    /**
+     * Lines 522, 523
+     * <p>
+     * Whether the conversation ID is chosen by the client or is generated by
+     * the system, the client may access the conversation ID by calling
+     * ServiceReference.getConversationID().
+     * <p>
+     * This test is following updates to this section of the specification per
+     * the OASIS TC under issue JAVA-31. The updated text reads: "...by calling
+     * getConversationID() on the current conversation object".
+     */
+    @Test
+    public void idAnnotation5() throws Exception {
+        aService.testAnnotation5();
+    }
+
 }



Mime
View raw message