[weld-commits] Weld SVN: r4760 - in cdi-tck/trunk/impl/src/main: java/org/jboss/jsr299/tck/tests/decorators/definition/broken/finalBeanMethod and 1 other directories.

weld-commits at lists.jboss.org weld-commits at lists.jboss.org
Sat Nov 7 18:13:42 EST 2009


Author: jharting
Date: 2009-11-07 18:13:41 -0500 (Sat, 07 Nov 2009)
New Revision: 4760

Modified:
   cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/broken/finalBeanClass/FinalBeanClassTest.java
   cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/broken/finalBeanMethod/FinalBeanMethodTest.java
   cdi-tck/trunk/impl/src/main/resources/tck-audit-cdi.xml
Log:
Matched tests with assertions.

Modified: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/broken/finalBeanClass/FinalBeanClassTest.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/broken/finalBeanClass/FinalBeanClassTest.java	2009-11-07 23:06:36 UTC (rev 4759)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/broken/finalBeanClass/FinalBeanClassTest.java	2009-11-07 23:13:41 UTC (rev 4760)
@@ -17,7 +17,7 @@
 package org.jboss.jsr299.tck.tests.decorators.definition.broken.finalBeanClass;
 
 import org.jboss.jsr299.tck.AbstractJSR299Test;
-import org.jboss.jsr299.tck.DefinitionError;
+import org.jboss.jsr299.tck.DeploymentError;
 import org.jboss.test.audit.annotations.SpecAssertion;
 import org.jboss.test.audit.annotations.SpecVersion;
 import org.jboss.testharness.impl.packaging.Artifact;
@@ -30,17 +30,18 @@
  *
  */
 @Artifact
- at ExpectedDeploymentException(DefinitionError.class)
+ at ExpectedDeploymentException(DeploymentError.class)
 @BeansXml("beans.xml")
 @SpecVersion(spec="cdi", version="20091101")
 public class FinalBeanClassTest extends AbstractJSR299Test
 {
 
-   @Test
-   @SpecAssertion(section="8.1.2", id="d")
+   @Test(groups = "ri-broken")
+   @SpecAssertion(section="8.3", id="ab")
+   // WELD-272
    public void testAppliesToFinalManagedBeanClass()
    {
-
+      assert false;
    }
 
 }

Modified: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/broken/finalBeanMethod/FinalBeanMethodTest.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/broken/finalBeanMethod/FinalBeanMethodTest.java	2009-11-07 23:06:36 UTC (rev 4759)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/broken/finalBeanMethod/FinalBeanMethodTest.java	2009-11-07 23:13:41 UTC (rev 4760)
@@ -17,7 +17,7 @@
 package org.jboss.jsr299.tck.tests.decorators.definition.broken.finalBeanMethod;
 
 import org.jboss.jsr299.tck.AbstractJSR299Test;
-import org.jboss.jsr299.tck.DefinitionError;
+import org.jboss.jsr299.tck.DeploymentError;
 import org.jboss.test.audit.annotations.SpecAssertion;
 import org.jboss.test.audit.annotations.SpecVersion;
 import org.jboss.testharness.impl.packaging.Artifact;
@@ -30,17 +30,18 @@
  *
  */
 @Artifact
- at ExpectedDeploymentException(DefinitionError.class)
+ at ExpectedDeploymentException(DeploymentError.class)
 @BeansXml("beans.xml")
 @SpecVersion(spec="cdi", version="20091101")
 public class FinalBeanMethodTest extends AbstractJSR299Test
 {
 
-   @Test
-   @SpecAssertion(section="8.1.2", id="e")
+   @Test(groups = "ri-broken")
+   @SpecAssertion(section="8.3", id="ac")
+   // WELD-272
    public void testAppliesToFinalMethodOnManagedBeanClass()
    {
-
+      assert false;
    }
 
 }

Modified: cdi-tck/trunk/impl/src/main/resources/tck-audit-cdi.xml
===================================================================
--- cdi-tck/trunk/impl/src/main/resources/tck-audit-cdi.xml	2009-11-07 23:06:36 UTC (rev 4759)
+++ cdi-tck/trunk/impl/src/main/resources/tck-audit-cdi.xml	2009-11-07 23:13:41 UTC (rev 4760)
@@ -4275,9 +4275,17 @@
 
   <section id="8.3" title="Decorator resolution">
     <assertion id="aa">
-      <text>The process of matching decorators to a certain bean is called decorator resolution.  A decorator is bound to a bean if the bean is assignable to the delegate injection point according to the rules defined in Section 5.3, "Typesafe resolution", and the decorator is enabled in the bean deployment archive of the bean. If a decorator matches a managed bean, and the managed bean class is declared final, the container automatically detects the problem and treats it as a deployment problem.</text>
+      <text>The process of matching decorators to a certain bean is called decorator resolution.  A decorator is bound to a bean if the bean is assignable to the delegate injection point according to the rules defined in Section 5.3, "Typesafe resolution", and the decorator is enabled in the bean deployment archive of the bean.</text>
     </assertion>
     
+    <assertion id="ab">
+      <text>If a decorator matches a managed bean, and the managed bean class is declared final, the container automatically detects the problem and treats it as a deployment problem.</text>
+    </assertion>
+    
+    <assertion id="ac">
+      <text>If a decorator matches a managed bean with a non-static, non-private, final method, and the decorator also implements that method, the container automatically detects the problem and treats it as a deployment problem.</text>
+    </assertion>
+    
     <assertion id="b">
       <text>For a custom implementation of the Decorator interface defined in Section 11.1.1, "The Decorator interface", the container calls |getDelegateType()|, |getDelegateQualifiers()| and |getDecoratedTypes()| to determine the delegate type and qualifiers and decorated types of the decorator.</text>
     </assertion>



More information about the weld-commits mailing list