tuscany-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sl...@apache.org
Subject svn commit: r1242718 - in /tuscany/sca-java-2.x/trunk: modules/implementation-java-runtime/src/test/java/org/apache/tuscany/sca/implementation/java/util/ modules/implementation-java/src/main/java/org/apache/tuscany/sca/implementation/java/introspect/ t...
Date Fri, 10 Feb 2012 09:43:24 GMT
Author: slaws
Date: Fri Feb 10 09:43:24 2012
New Revision: 1242718

URL: http://svn.apache.org/viewvc?rev=1242718&view=rev
Log:
TUSCANY-3924 - revert some of the previous changes. we need to look at whether we are interpreting
the spec correctly

Modified:
    tuscany/sca-java-2.x/trunk/modules/implementation-java-runtime/src/test/java/org/apache/tuscany/sca/implementation/java/util/Bean1.java
    tuscany/sca-java-2.x/trunk/modules/implementation-java-runtime/src/test/java/org/apache/tuscany/sca/implementation/java/util/JavaIntrospectionHelperTestCase.java
    tuscany/sca-java-2.x/trunk/modules/implementation-java/src/main/java/org/apache/tuscany/sca/implementation/java/introspect/JavaIntrospectionHelper.java
    tuscany/sca-java-2.x/trunk/testing/itest/properties/src/main/resources/CTCalcTest.composite
    tuscany/sca-java-2.x/trunk/testing/itest/properties/src/test/java/org/apache/tuscany/sca/itest/ctcalc/CTCalcTestCase.java

Modified: tuscany/sca-java-2.x/trunk/modules/implementation-java-runtime/src/test/java/org/apache/tuscany/sca/implementation/java/util/Bean1.java
URL: http://svn.apache.org/viewvc/tuscany/sca-java-2.x/trunk/modules/implementation-java-runtime/src/test/java/org/apache/tuscany/sca/implementation/java/util/Bean1.java?rev=1242718&r1=1242717&r2=1242718&view=diff
==============================================================================
--- tuscany/sca-java-2.x/trunk/modules/implementation-java-runtime/src/test/java/org/apache/tuscany/sca/implementation/java/util/Bean1.java
(original)
+++ tuscany/sca-java-2.x/trunk/modules/implementation-java-runtime/src/test/java/org/apache/tuscany/sca/implementation/java/util/Bean1.java
Fri Feb 10 09:43:24 2012
@@ -25,9 +25,9 @@ package org.apache.tuscany.sca.implement
  */
 public class Bean1 extends SuperBean {
 
-    public static final int ALL_BEAN1_FIELDS = 6; //TUSCANY-3924 + ALL_SUPER_FIELDS;
-    public static final int ALL_BEAN1_PUBLIC_PROTECTED_FIELDS = 5; //TUSCANY-3924 + ALL_SUPER_PUBLIC_PROTECTED_FIELDS;
-    public static final int ALL_BEAN1_METHODS = 4; //TUSCANY-3924 + ALL_SUPER_METHODS - 1;
+    public static final int ALL_BEAN1_FIELDS = 6 + ALL_SUPER_FIELDS;
+    public static final int ALL_BEAN1_PUBLIC_PROTECTED_FIELDS = 5 + ALL_SUPER_PUBLIC_PROTECTED_FIELDS;
+    public static final int ALL_BEAN1_METHODS = 4 + ALL_SUPER_METHODS - 1;
     public String field3;
     protected String field2;
     private String field1;

Modified: tuscany/sca-java-2.x/trunk/modules/implementation-java-runtime/src/test/java/org/apache/tuscany/sca/implementation/java/util/JavaIntrospectionHelperTestCase.java
URL: http://svn.apache.org/viewvc/tuscany/sca-java-2.x/trunk/modules/implementation-java-runtime/src/test/java/org/apache/tuscany/sca/implementation/java/util/JavaIntrospectionHelperTestCase.java?rev=1242718&r1=1242717&r2=1242718&view=diff
==============================================================================
--- tuscany/sca-java-2.x/trunk/modules/implementation-java-runtime/src/test/java/org/apache/tuscany/sca/implementation/java/util/JavaIntrospectionHelperTestCase.java
(original)
+++ tuscany/sca-java-2.x/trunk/modules/implementation-java-runtime/src/test/java/org/apache/tuscany/sca/implementation/java/util/JavaIntrospectionHelperTestCase.java
Fri Feb 10 09:43:24 2012
@@ -29,7 +29,6 @@ import java.util.Map;
 import java.util.Set;
 
 import org.apache.tuscany.sca.implementation.java.introspect.JavaIntrospectionHelper;
-import org.junit.Ignore;
 import org.junit.Test;
 
 /**
@@ -47,7 +46,7 @@ public class JavaIntrospectionHelperTest
     @Test
     public void testBean1AllPublicProtectedFields() throws Exception {
         Set<Field> beanFields = JavaIntrospectionHelper.getAllPublicAndProtectedFields(Bean1.class,
true);
-        assertEquals(2, beanFields.size());                //Bean1.ALL_BEAN1_PUBLIC_PROTECTED_FIELDS
+        assertEquals(4, beanFields.size());                //Bean1.ALL_BEAN1_PUBLIC_PROTECTED_FIELDS
     }
 
     @Test
@@ -76,8 +75,7 @@ public class JavaIntrospectionHelperTest
             throw new Exception("Override never invoked");
         }
     }
-    
-    @Ignore("TUSCANY-3924")
+
     @Test
     public void testNoOverrideMethod() throws Exception {
         Set<Method> beanFields = JavaIntrospectionHelper.getAllUniquePublicProtectedMethods(Bean1.class,
true);

Modified: tuscany/sca-java-2.x/trunk/modules/implementation-java/src/main/java/org/apache/tuscany/sca/implementation/java/introspect/JavaIntrospectionHelper.java
URL: http://svn.apache.org/viewvc/tuscany/sca-java-2.x/trunk/modules/implementation-java/src/main/java/org/apache/tuscany/sca/implementation/java/introspect/JavaIntrospectionHelper.java?rev=1242718&r1=1242717&r2=1242718&view=diff
==============================================================================
--- tuscany/sca-java-2.x/trunk/modules/implementation-java/src/main/java/org/apache/tuscany/sca/implementation/java/introspect/JavaIntrospectionHelper.java
(original)
+++ tuscany/sca-java-2.x/trunk/modules/implementation-java/src/main/java/org/apache/tuscany/sca/implementation/java/introspect/JavaIntrospectionHelper.java
Fri Feb 10 09:43:24 2012
@@ -83,8 +83,7 @@ public final class JavaIntrospectionHelp
         if (clazz == null || clazz.isArray() || Object.class.equals(clazz)) {
             return fields;
         }
-        // TUSCANY-3924 - don't consider inherited fields
-        //fields = getAllPublicAndProtectedFields(clazz.getSuperclass(), fields, validating);
+        fields = getAllPublicAndProtectedFields(clazz.getSuperclass(), fields, validating);
 
         Field[] declaredFields = null;
 
@@ -137,8 +136,7 @@ public final class JavaIntrospectionHelp
             return fields;
         }
 
-        // TUSCANY-3924 - don't consider inherited fields
-        //fields = getInjectableFields(clazz.getSuperclass(), fields, validating);
+        fields = getInjectableFields(clazz.getSuperclass(), fields, validating);
 
         Field[] declaredFields = null;
 
@@ -237,8 +235,7 @@ public final class JavaIntrospectionHelp
         }
         // evaluate class hierarchy - this is done last to track inherited
         // methods
-        // TUSCANY-3924 - don't consider inherited fields
-        //methods = getAllUniqueMethods(pClass.getSuperclass(), methods, validating);
+        methods = getAllUniqueMethods(pClass.getSuperclass(), methods, validating);
         return methods;
     }
 

Modified: tuscany/sca-java-2.x/trunk/testing/itest/properties/src/main/resources/CTCalcTest.composite
URL: http://svn.apache.org/viewvc/tuscany/sca-java-2.x/trunk/testing/itest/properties/src/main/resources/CTCalcTest.composite?rev=1242718&r1=1242717&r2=1242718&view=diff
==============================================================================
--- tuscany/sca-java-2.x/trunk/testing/itest/properties/src/main/resources/CTCalcTest.composite
(original)
+++ tuscany/sca-java-2.x/trunk/testing/itest/properties/src/main/resources/CTCalcTest.composite
Fri Feb 10 09:43:24 2012
@@ -35,10 +35,8 @@
     
     <component name="Annotated2Component">
         <implementation.java class="org.apache.tuscany.sca.itest.ctcalc.Annotated2CTCalcComponentImpl"
/>
-        <property name="aPropertyAnnotated" value="xyz"/>
-<!-- TUSCANY-3924 playing with whether we should take note of inherited annotations as
per JSR-250       
+        <property name="aPropertyAnnotated" value="xyz"/>    
         <property name="aPropertyPublic" value="abc"/>
- -->
     </component> 
 
 </composite>

Modified: tuscany/sca-java-2.x/trunk/testing/itest/properties/src/test/java/org/apache/tuscany/sca/itest/ctcalc/CTCalcTestCase.java
URL: http://svn.apache.org/viewvc/tuscany/sca-java-2.x/trunk/testing/itest/properties/src/test/java/org/apache/tuscany/sca/itest/ctcalc/CTCalcTestCase.java?rev=1242718&r1=1242717&r2=1242718&view=diff
==============================================================================
--- tuscany/sca-java-2.x/trunk/testing/itest/properties/src/test/java/org/apache/tuscany/sca/itest/ctcalc/CTCalcTestCase.java
(original)
+++ tuscany/sca-java-2.x/trunk/testing/itest/properties/src/test/java/org/apache/tuscany/sca/itest/ctcalc/CTCalcTestCase.java
Fri Feb 10 09:43:24 2012
@@ -84,7 +84,7 @@ public class CTCalcTestCase {
     @Test
     public void testUnannotatedExtension() {
         assertEquals("Unannotated", unannotatedComponent.test());
-        assertEquals(2, ((NodeImpl)node).getDomainComposite().getComponents().get(1).getProperties().size());
+        assertEquals(4, ((NodeImpl)node).getDomainComposite().getComponents().get(1).getProperties().size());
         System.out.println(((NodeImpl)node).getDomainComposite().getComponents().get(1).getProperties());
     }
 
@@ -95,7 +95,6 @@ public class CTCalcTestCase {
         System.out.println(((NodeImpl)node).getDomainComposite().getComponents().get(2).getProperties());
     }
     
-    @Ignore("TUSCANY-3924 playing with whether we should take note of inherited annotations
as per JSR-250")
     @Test
     public void testAnnotated2Extension() {
         assertEquals("Annotated", annotatedComponent.test());



Mime
View raw message