Weld SVN: r4231 - build/trunk/dist.
by weld-commits@lists.jboss.org
Author: dan.j.allen
Date: 2009-10-22 18:47:10 -0400 (Thu, 22 Oct 2009)
New Revision: 4231
Modified:
build/trunk/dist/readme.txt
Log:
update system requirements
Modified: build/trunk/dist/readme.txt
===================================================================
--- build/trunk/dist/readme.txt 2009-10-22 22:27:23 UTC (rev 4230)
+++ build/trunk/dist/readme.txt 2009-10-22 22:47:10 UTC (rev 4231)
@@ -16,8 +16,15 @@
System requirements
===================
- JDK 5.0 or above.
+ Weld 1.0 requires a Java EE 6 application server, a servlet container (using
+ the servlet extension) and Java SE (using the Java SE extension).
+
+ You must use JBoss AS 5.2.0.Beta1 (use nightly builds until released) or above
+ to deploy the provided examples out of the box. Other application servers may
+ be supported by the examples in the 1.0.0 release.
+ JDK 5.0 or JDK 6.0 is required for all Weld releases.
+
Contents of distribution
========================
15 years, 1 month
Weld SVN: r4230 - build/trunk/dist.
by weld-commits@lists.jboss.org
Author: dan.j.allen
Date: 2009-10-22 18:27:23 -0400 (Thu, 22 Oct 2009)
New Revision: 4230
Modified:
build/trunk/dist/readme.txt
Log:
borrow readme.txt format from Hibernate Validator to make it look more professional
Modified: build/trunk/dist/readme.txt
===================================================================
--- build/trunk/dist/readme.txt 2009-10-22 21:52:32 UTC (rev 4229)
+++ build/trunk/dist/readme.txt 2009-10-22 22:27:23 UTC (rev 4230)
@@ -1,29 +1,64 @@
-Weld
-------------
-Java Contexts and Dependency Injection for the Java EE platform (JSR-299) is a
-new Java standard for dependency injection and contextual lifecycle management.
-Weld is the reference implementation of JSR-299.
+ Weld
-This distribution, as a whole, is licensed under the terms of the Apache
-License, Version 2.0 (see apl.txt).
+ What is it?
+ ============
-This distribution consists of:
+ Weld is the reference implementation of JSR-299: Java Contents and Dependency
+ Injection for the Java EE platform (CDI). JSR-299 is the new Java standard for
+ dependency injection and contextual life cycle management.
-doc/
- -- The Reference guide, take a look at doc/en-US/html/index.html for getting
- started using Weld and the facilities offered by JSR-299.
-
-examples/
- -- The Weld examples, the examples are described in more detail in the
- reference guide
+ Status
+ =======
+
+ This is a preproduction release of Weld.
+
+ System requirements
+ ===================
+
+ JDK 5.0 or above.
+
+ Contents of distribution
+ ========================
+
+ doc/
+
+ API Docs and reference guide. Open doc/en-US/html/index.html in your
+ browser for instructions on how to get started using Weld and the
+ facilities offered by JSR-299.
-jboss-as/
- -- Installer for JBoss AS, change into this directory, and run ant update
- There are more details in the reference guide
+ examples/
-lib/
- -- Libraries, for building the examples
-
-lib/weld
- -- Weld binary, source and javadoc jars
+ The Weld examples, the examples are described in more detail in the
+ reference guide
+
+ jboss-as/
+
+ Installer for JBoss AS, change into this directory, and run ant update
+ There are more details in the reference guide
+
+ lib/
+
+ Libraries, for building the examples
+
+ lib/weld
+
+ Weld binary, source and javadoc jars
+
+ Licensing
+ =========
+
+ This distribution, as a whole, is licensed under the terms of the Apache
+ License, Version 2.0 (see apl.txt).
+
+ Weld URLs
+ =========
+
+ Home Page: http://seamframework.org/Weld
+ Downloads: http://seamframework.org/Download/SeamDownloads#H-WeldAndJSR299TCKReleases
+ Mailing Lists: https://lists.jboss.org/mailman/listinfo/weld-dev
+ Source Code: http://anonsvn.jboss.org/repos/weld
+ Issue Tracking: https://jira.jboss.org/jira/browse/WELD (core)
+ https://jira.jboss.org/jira/browse/WELDX (extensions)
+ https://jira.jboss.org/jira/browse/WELDINT (JBoss AS integration)
+
15 years, 1 month
Weld SVN: r4229 - examples/trunk.
by weld-commits@lists.jboss.org
Author: dan.j.allen
Date: 2009-10-22 17:52:32 -0400 (Thu, 22 Oct 2009)
New Revision: 4229
Modified:
examples/trunk/readme.txt
Log:
mention the login example, which is included in the release
Modified: examples/trunk/readme.txt
===================================================================
--- examples/trunk/readme.txt 2009-10-22 21:42:58 UTC (rev 4228)
+++ examples/trunk/readme.txt 2009-10-22 21:52:32 UTC (rev 4229)
@@ -1,7 +1,8 @@
Weld currently comes with a number of examples:
* jsf/numberguess (a war example for JSF)
-* jsf/translator (an EJB example for JSF).
+* jsf/login (another war example for JSF)
+* jsf/translator (an EJB example for JSF)
* se/numberguess (the numberguess example for Java SE using Swing)
* se/helloworld (a simple example for Java SE)
* wicket/numberguess (the numberguess example for Wicket)
15 years, 1 month
Weld SVN: r4228 - build/trunk/dist.
by weld-commits@lists.jboss.org
Author: dan.j.allen
Date: 2009-10-22 17:42:58 -0400 (Thu, 22 Oct 2009)
New Revision: 4228
Modified:
build/trunk/dist/build.xml
build/trunk/dist/readme.txt
Log:
add apl.txt to dist
reflect new name of JSR-299 (with the "for the Java EE platform" part)
Modified: build/trunk/dist/build.xml
===================================================================
--- build/trunk/dist/build.xml 2009-10-22 14:40:28 UTC (rev 4227)
+++ build/trunk/dist/build.xml 2009-10-22 21:42:58 UTC (rev 4228)
@@ -42,6 +42,7 @@
</fileset>
<fileset dir="${basedir}">
<include name="readme.txt" />
+ <include name="apl.txt" />
</fileset>
</copy>
Modified: build/trunk/dist/readme.txt
===================================================================
--- build/trunk/dist/readme.txt 2009-10-22 14:40:28 UTC (rev 4227)
+++ build/trunk/dist/readme.txt 2009-10-22 21:42:58 UTC (rev 4228)
@@ -1,12 +1,12 @@
Weld
------------
-Java Contexts and Dependency Injection (JSR-299) is a new Java standard for
-dependency injection and contextual lifecycle management. Weld is the
-reference implementation of JSR-299.
+Java Contexts and Dependency Injection for the Java EE platform (JSR-299) is a
+new Java standard for dependency injection and contextual lifecycle management.
+Weld is the reference implementation of JSR-299.
-This distribution, as a whole, is licensed under the terms of the Apache Public
-License (see apl.txt).
+This distribution, as a whole, is licensed under the terms of the Apache
+License, Version 2.0 (see apl.txt).
This distribution consists of:
15 years, 1 month
Weld SVN: r4227 - core/trunk/bom.
by weld-commits@lists.jboss.org
Author: marius.bogoevici
Date: 2009-10-22 10:40:28 -0400 (Thu, 22 Oct 2009)
New Revision: 4227
Modified:
core/trunk/bom/pom.xml
Log:
Set jboss-interceptors version to 1.0.0-CR4.
Modified: core/trunk/bom/pom.xml
===================================================================
--- core/trunk/bom/pom.xml 2009-10-22 14:31:29 UTC (rev 4226)
+++ core/trunk/bom/pom.xml 2009-10-22 14:40:28 UTC (rev 4227)
@@ -76,7 +76,7 @@
<javassist.version>3.11.0.GA</javassist.version>
<cdi.tck.version>1.0.0-SNAPSHOT</cdi.tck.version>
<atinject.tck.version>1.0.0-PFD-3</atinject.tck.version>
- <jboss.interceptor.version>1.0.0-SNAPSHOT</jboss.interceptor.version>
+ <jboss.interceptor.version>1.0.0-CR4</jboss.interceptor.version>
<slf4j.version>1.5.8</slf4j.version>
</properties>
15 years, 1 month
Weld SVN: r4226 - cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event.
by weld-commits@lists.jboss.org
Author: jharting
Date: 2009-10-22 10:31:29 -0400 (Thu, 22 Oct 2009)
New Revision: 4226
Modified:
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/ContainerEventTest.java
Log:
minor
Modified: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/ContainerEventTest.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/ContainerEventTest.java 2009-10-22 12:52:15 UTC (rev 4225)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/ContainerEventTest.java 2009-10-22 14:31:29 UTC (rev 4226)
@@ -84,9 +84,7 @@
@Test
@SpecAssertions({
@SpecAssertion(section="11.5.6", id="aal"),
- @SpecAssertion(section="11.5.6", id="aam"),
- @SpecAssertion(section="11.5.6", id="aau"),
- @SpecAssertion(section="11.5.6", id="aav")
+ @SpecAssertion(section="11.5.6", id="aam")
})
public void testTypeOfProcessInjectionTargetParameter() {
assert ProcessInjectionTargetObserver.getEvent1Observed() == 0;
15 years, 1 month
Weld SVN: r4225 - in cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests: extensions/alternative and 4 other directories.
by weld-commits@lists.jboss.org
Author: jharting
Date: 2009-10-22 08:52:15 -0400 (Thu, 22 Oct 2009)
New Revision: 4225
Added:
cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/alternative/
cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/alternative/metadata/
cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/alternative/metadata/beans.xml
cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/alternative/metadata/javax.enterprise.inject.spi.Extension
Removed:
cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/annotated/beans.xml
cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/lookup/injection/enterprise/javax.enterprise.inject.spi.Extension
Modified:
cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/lookup/injection/non/contextual/javax.enterprise.inject.spi.Extension
Log:
Test resources for chapters 11, 12
Added: cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/alternative/metadata/beans.xml
===================================================================
--- cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/alternative/metadata/beans.xml (rev 0)
+++ cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/alternative/metadata/beans.xml 2009-10-22 12:52:15 UTC (rev 4225)
@@ -0,0 +1,5 @@
+<beans>
+ <interceptors>
+ <class>org.jboss.jsr299.tck.tests.extensions.alternative.metadata.GroceryInterceptor</class>
+ </interceptors>
+</beans>
Added: cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/alternative/metadata/javax.enterprise.inject.spi.Extension
===================================================================
--- cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/alternative/metadata/javax.enterprise.inject.spi.Extension (rev 0)
+++ cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/alternative/metadata/javax.enterprise.inject.spi.Extension 2009-10-22 12:52:15 UTC (rev 4225)
@@ -0,0 +1 @@
+org.jboss.jsr299.tck.tests.extensions.alternative.metadata.ProcessAnnotatedTypeObserver
Deleted: cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/annotated/beans.xml
===================================================================
--- cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/annotated/beans.xml 2009-10-22 12:50:07 UTC (rev 4224)
+++ cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/annotated/beans.xml 2009-10-22 12:52:15 UTC (rev 4225)
@@ -1,5 +0,0 @@
-<beans>
- <interceptors>
- <class>org.jboss.jsr299.tck.tests.extensions.annotated.GroceryInterceptor</class>
- </interceptors>
-</beans>
Deleted: cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/lookup/injection/enterprise/javax.enterprise.inject.spi.Extension
===================================================================
--- cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/lookup/injection/enterprise/javax.enterprise.inject.spi.Extension 2009-10-22 12:50:07 UTC (rev 4224)
+++ cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/lookup/injection/enterprise/javax.enterprise.inject.spi.Extension 2009-10-22 12:52:15 UTC (rev 4225)
@@ -1 +0,0 @@
-org.jboss.jsr299.tck.tests.lookup.injection.enterprise.ProcessInjectionTargetEventObserver
\ No newline at end of file
Modified: cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/lookup/injection/non/contextual/javax.enterprise.inject.spi.Extension
===================================================================
--- cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/lookup/injection/non/contextual/javax.enterprise.inject.spi.Extension 2009-10-22 12:50:07 UTC (rev 4224)
+++ cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/lookup/injection/non/contextual/javax.enterprise.inject.spi.Extension 2009-10-22 12:52:15 UTC (rev 4225)
@@ -1 +1,2 @@
-org.jboss.jsr299.tck.tests.lookup.injection.non.contextual.ProcessInjectionTargetEventObserver
\ No newline at end of file
+org.jboss.jsr299.tck.tests.lookup.injection.non.contextual.ProcessInjectionTargetObserver
+org.jboss.jsr299.tck.tests.lookup.injection.non.contextual.ProcessAnnotatedTypeObserver
15 years, 1 month
Weld SVN: r4224 - cdi-tck/trunk/impl/src/main/resources.
by weld-commits@lists.jboss.org
Author: jharting
Date: 2009-10-22 08:50:07 -0400 (Thu, 22 Oct 2009)
New Revision: 4224
Modified:
cdi-tck/trunk/impl/src/main/resources/tck-audit-cdi.xml
Log:
Removed incorrect assertions
Modified: cdi-tck/trunk/impl/src/main/resources/tck-audit-cdi.xml
===================================================================
--- cdi-tck/trunk/impl/src/main/resources/tck-audit-cdi.xml 2009-10-22 12:45:59 UTC (rev 4223)
+++ cdi-tck/trunk/impl/src/main/resources/tck-audit-cdi.xml 2009-10-22 12:50:07 UTC (rev 4224)
@@ -5709,12 +5709,6 @@
<assertion id="aai">
<text>Test event is fired for a filter</text>
</assertion>
- <assertion id="aaj">
- <text>Test event is fired for a producer method</text>
- </assertion>
- <assertion id="aak">
- <text>Test event is fired for a producer field</text>
- </assertion>
<assertion id="aal">
<text>Test type for a managed bean</text>
</assertion>
@@ -5742,12 +5736,6 @@
<assertion id="aat">
<text>Test type for a filter</text>
</assertion>
- <assertion id="aau">
- <text>Test type for a producer method</text>
- </assertion>
- <assertion id="aav">
- <text>Test type for a producer field</text>
- </assertion>
</group>
<group>
@@ -5779,12 +5767,6 @@
<assertion id="abi">
<text>Test type for a filter</text>
</assertion>
- <assertion id="abj">
- <text>Test type for a producer method</text>
- </assertion>
- <assertion id="abk">
- <text>Test type for a producer field</text>
- </assertion>
</group>
<assertion id="bb">
@@ -5824,12 +5806,6 @@
<assertion id="ei">
<text>Test type for a filter</text>
</assertion>
- <assertion id="ej">
- <text>Test type for a producer method</text>
- </assertion>
- <assertion id="ek">
- <text>Test type for a producer field</text>
- </assertion>
</group>
<assertion id="f">
@@ -6242,43 +6218,37 @@
<group>
<text>For each Java class in any bean deployment archive, the container must, if the class is a managed bean, session bean, producer method or field, or other Java EE component class supporting injection, create an |InjectionTarget| for the class, as defined in Section 11.2, "The Producer and InjectionTarget interfaces", and fire an event of type |ProcessInjectionTarget|, as defined in Section 11.5.6, "ProcessInjectionTarget event"</text>
- <assertion id="ba">
+ <assertion id="da">
<text>Check managed bean</text>
</assertion>
- <assertion id="bb">
+ <assertion id="db">
<text>Check session bean</text>
</assertion>
- <assertion id="bb">
- <text>Check producer field</text>
- </assertion>
- <assertion id="bb">
- <text>Check producer method</text>
- </assertion>
- <assertion id="bc">
+ <assertion id="dc">
<text>Check non-contextual session bean</text>
</assertion>
- <assertion id="bd">
+ <assertion id="dd">
<text>Check JSF managed beans</text>
</assertion>
- <assertion id="be">
+ <assertion id="de">
<text>Check servlet listener</text>
</assertion>
- <assertion id="bf">
+ <assertion id="df">
<text>Check tag handler</text>
</assertion>
- <assertion id="bg">
+ <assertion id="dg">
<text>Check tag library listener</text>
</assertion>
- <assertion id="bh">
+ <assertion id="dh">
<text>Check EJB Interceptor</text>
</assertion>
- <assertion id="bi">
+ <assertion id="di">
<text>Check WS endpoint</text>
</assertion>
- <assertion id="bj">
+ <assertion id="dj">
<text>Check servlet</text>
</assertion>
- <assertion id="bk">
+ <assertion id="dk">
<text>Check filter</text>
</assertion>
</group>
15 years, 1 month
Weld SVN: r4223 - in cdi-tck/trunk/impl/src/main: java/org/jboss/jsr299/tck/tests/extensions/container and 10 other directories.
by weld-commits@lists.jboss.org
Author: jharting
Date: 2009-10-22 08:45:59 -0400 (Thu, 22 Oct 2009)
New Revision: 4223
Added:
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Cheese.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/ContainerEventTest.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Cow.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/CowLocal.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Farm.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Food.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Milk.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/ProcessAnnotatedTypeObserver.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/ProcessBeanObserver.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/ProcessInjectionTargetObserver.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Sheep.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/SheepInterceptor.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/SheepLocal.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Tame.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverRegistersException/
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverRegistersException/AddDefinitionErrorTest.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverRegistersException/ProcessBeanObserver.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverRegistersException/Sheep.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverThrowsException/
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverThrowsException/ProcessBeanObserver.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverThrowsException/Sheep.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverThrowsException/ThrowExceptionInProcessBeanObserverTest.java
cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/
cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/event/
cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/event/broken/
cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverRegistersException/
cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverRegistersException/javax.enterprise.inject.spi.Extension
cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverThrowsException/
cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverThrowsException/javax.enterprise.inject.spi.Extension
cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/event/ejb-jar.xml
cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/event/javax.enterprise.inject.spi.Extension
Log:
Tests for 11.5.8 and 12.3
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Cheese.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Cheese.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Cheese.java 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,9 @@
+package org.jboss.jsr299.tck.tests.extensions.container.event;
+
+class Cheese extends Food
+{
+ public Cheese(boolean fresh)
+ {
+ super(fresh);
+ }
+}
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/ContainerEventTest.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/ContainerEventTest.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/ContainerEventTest.java 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,185 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed 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.
+ */
+package org.jboss.jsr299.tck.tests.extensions.container.event;
+
+import javax.ejb.Stateless;
+import javax.enterprise.inject.Produces;
+import javax.enterprise.inject.spi.Annotated;
+import javax.enterprise.inject.spi.AnnotatedType;
+
+import static javax.enterprise.inject.spi.SessionBeanType.STATELESS;
+import static javax.enterprise.inject.spi.SessionBeanType.STATEFUL;
+
+import org.jboss.jsr299.tck.AbstractJSR299Test;
+import org.jboss.test.audit.annotations.SpecAssertion;
+import org.jboss.test.audit.annotations.SpecAssertions;
+import org.jboss.test.audit.annotations.SpecVersion;
+import org.jboss.testharness.impl.packaging.Artifact;
+import org.jboss.testharness.impl.packaging.IntegrationTest;
+import org.jboss.testharness.impl.packaging.Packaging;
+import org.jboss.testharness.impl.packaging.PackagingType;
+import org.jboss.testharness.impl.packaging.Resource;
+import org.jboss.testharness.impl.packaging.Resources;
+import org.testng.annotations.Test;
+
+/**
+ * Tests for ProcessAnnotatedType, ProcessBean and ProcessInjectionTarget events.
+ * @author Jozef Hartinger
+ *
+ */
+@Artifact
+@Resources({
+ @Resource(source = "javax.enterprise.inject.spi.Extension", destination = "META-INF/services/javax.enterprise.inject.spi.Extension"),
+ @Resource(source = "ejb-jar.xml", destination = "META-INF/ejb-jar.xml")})
+@IntegrationTest
+@SpecVersion(spec = "cdi", version = "20091018")
+(a)Packaging(PackagingType.EAR)
+public class ContainerEventTest extends AbstractJSR299Test
+{
+ @Test
+ @SpecAssertions({
+ @SpecAssertion(section = "12.3", id = "ba"),
+ @SpecAssertion(section = "11.5.6", id = "aaa")})
+ public void testProcessInjectionTargetFiredForManagedBean() {
+ assert ProcessInjectionTargetObserver.getManagedBeanEvent() != null;
+ validateManagedBean(ProcessInjectionTargetObserver.getManagedBeanEvent().getAnnotatedType());
+ }
+
+ @Test
+ @SpecAssertions({
+ @SpecAssertion(section = "11.5.6", id = "aab"),
+ @SpecAssertion(section = "11.5.6", id = "abb"),
+ @SpecAssertion(section = "12.3", id = "db")})
+ public void testProcessInjectionTargetFiredForSessionBean() {
+ assert ProcessInjectionTargetObserver.getStatelessSessionBeanEvent() != null;
+ assert ProcessInjectionTargetObserver.getStatefulSessionBeanEvent() != null;
+ validateStatelessSessionBean(ProcessInjectionTargetObserver.getStatelessSessionBeanEvent().getAnnotatedType());
+ validateStatefulSessionBean(ProcessInjectionTargetObserver.getStatefulSessionBeanEvent().getAnnotatedType());
+ }
+
+ @Test
+ @SpecAssertions({
+ @SpecAssertion(section = "11.5.6", id = "aaf"),
+ @SpecAssertion(section = "11.5.6", id = "abf"),
+ @SpecAssertion(section = "12.3", id = "dh")})
+ public void testProcessInjectionTargetFiredForSessionBeanInterceptor() {
+ assert ProcessInjectionTargetObserver.getSessionBeanInterceptorEvent() != null;
+ validateSessionBeanInterceptor(ProcessInjectionTargetObserver.getSessionBeanInterceptorEvent().getAnnotatedType());
+ }
+
+ @Test
+ @SpecAssertions({
+ @SpecAssertion(section="11.5.6", id="aal"),
+ @SpecAssertion(section="11.5.6", id="aam"),
+ @SpecAssertion(section="11.5.6", id="aau"),
+ @SpecAssertion(section="11.5.6", id="aav")
+ })
+ public void testTypeOfProcessInjectionTargetParameter() {
+ assert ProcessInjectionTargetObserver.getEvent1Observed() == 0;
+ assert ProcessInjectionTargetObserver.getEvent2Observed() == 0;
+ assert ProcessInjectionTargetObserver.getEvent3Observed() == 0;
+ assert ProcessInjectionTargetObserver.getEvent4Observed() == 0;
+ assert ProcessInjectionTargetObserver.getEvent5Observed() == 1;
+ }
+
+ @Test
+ @SpecAssertion(section = "12.3", id= "bb")
+ public void testProcessAnnotatedTypeFiredForSessionBean() {
+ assert ProcessAnnotatedTypeObserver.getStatelessSessionBeanEvent() != null;
+ assert ProcessAnnotatedTypeObserver.getStatefulSessionBeanEvent() != null;
+ validateStatelessSessionBean(ProcessAnnotatedTypeObserver.getStatelessSessionBeanEvent().getAnnotatedType());
+ validateStatefulSessionBean(ProcessAnnotatedTypeObserver.getStatefulSessionBeanEvent().getAnnotatedType());
+ }
+
+ @Test
+ @SpecAssertion(section = "12.3", id= "bh")
+ public void testProcessAnnotatedTypeFiredForSessionBeanInterceptor() {
+ assert ProcessAnnotatedTypeObserver.getSessionBeanInterceptorEvent() != null;
+ validateSessionBeanInterceptor(ProcessAnnotatedTypeObserver.getSessionBeanInterceptorEvent().getAnnotatedType());
+ }
+
+ @Test
+ @SpecAssertion(section = "11.5.8", id = "ba")
+ public void testProcessManagedBeanFired()
+ {
+ assert ProcessBeanObserver.getProcessManagedBeanEvent() != null;
+ validateManagedBean(ProcessBeanObserver.getProcessManagedBeanEvent().getAnnotatedBeanClass());
+ }
+
+ @Test
+ @SpecAssertions({
+ @SpecAssertion(section="11.5.8", id="c"),
+ @SpecAssertion(section="12.3", id="fb")})
+ public void testProcessSessionBeanFiredForStatelessSessionBean() {
+ assert ProcessBeanObserver.getProcessStatelessSessionBeanEvent() != null;
+ validateStatelessSessionBean(ProcessBeanObserver.getProcessStatelessSessionBeanEvent().getAnnotatedSessionBeanClass());
+ }
+
+ @Test
+ @SpecAssertions({
+ @SpecAssertion(section="11.5.8", id="c"),
+ @SpecAssertion(section="12.3", id="fb"),
+ @SpecAssertion(section="12.3", id="g")})
+ public void testProcessSessionBeanFiredForStatefulSessionBean() {
+ assert ProcessBeanObserver.getProcessStatefulSessionBeanEvent() != null;
+ validateStatefulSessionBean(ProcessBeanObserver.getProcessStatefulSessionBeanEvent().getAnnotatedSessionBeanClass());
+ }
+
+ @Test
+ @SpecAssertion(section="11.5.8", id="hb")
+ public void testGetEJBName() {
+ assert ProcessBeanObserver.getProcessStatelessSessionBeanEvent().getEjbName().equals("sheep");
+ assert ProcessBeanObserver.getProcessStatefulSessionBeanEvent().getEjbName().equals("cow");
+ }
+
+ @Test
+ @SpecAssertion(section="11.5.8", id="hc")
+ public void testGetSessionBeanType() {
+ assert ProcessBeanObserver.getProcessStatelessSessionBeanEvent().getSessionBeanType().equals(STATELESS);
+ assert ProcessBeanObserver.getProcessStatefulSessionBeanEvent().getSessionBeanType().equals(STATEFUL);
+ }
+
+ private void validateStatelessSessionBean(Annotated type) {
+ assert type.getBaseType().equals(Sheep.class);
+ assert typeSetMatches(type.getTypeClosure(), Sheep.class, SheepLocal.class, Object.class);
+ assert type.getAnnotations().size() == 2;
+ assert annotationSetMatches(type.getAnnotations(), Tame.class, Stateless.class); //TODO Check
+ }
+
+ private void validateStatefulSessionBean(Annotated type) {
+ assert type.getBaseType().equals(Cow.class);
+ assert typeSetMatches(type.getTypeClosure(), Cow.class, CowLocal.class, Object.class);
+ assert type.getAnnotations().size() == 0;
+ }
+
+ private void validateSessionBeanInterceptor(AnnotatedType<SheepInterceptor> type) {
+ assert type.getBaseType().equals(SheepInterceptor.class);
+ assert typeSetMatches(type.getTypeClosure(), SheepInterceptor.class, Object.class);
+ assert type.getAnnotations().size() == 0;
+ assert type.getFields().size() == 0;
+ assert type.getMethods().size() == 1;
+ }
+
+ private void validateManagedBean(AnnotatedType<Farm> type) {
+ assert type.getBaseType().equals(Farm.class);
+ assert typeSetMatches(type.getTypeClosure(), Farm.class, Object.class);
+ assert type.getFields().size() == 1;
+ assert type.getFields().iterator().next().isAnnotationPresent(Produces.class);
+ assert type.getMethods().size() == 1;
+ assert type.getMethods().iterator().next().isAnnotationPresent(Produces.class);
+ }
+}
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Cow.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Cow.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Cow.java 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,10 @@
+package org.jboss.jsr299.tck.tests.extensions.container.event;
+
+/**
+ * This is a stateful session bean defined in ejb-jar.xml
+ *
+ */
+public class Cow implements CowLocal
+{
+
+}
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/CowLocal.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/CowLocal.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/CowLocal.java 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,9 @@
+package org.jboss.jsr299.tck.tests.extensions.container.event;
+
+/**
+ * This is a local interface for a session bean defined in ejb-jar.xml
+ *
+ */
+public interface CowLocal
+{
+}
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Farm.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Farm.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Farm.java 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,15 @@
+package org.jboss.jsr299.tck.tests.extensions.container.event;
+
+import javax.enterprise.inject.Produces;
+
+class Farm
+{
+ @SuppressWarnings("unused")
+ @Produces
+ private Milk milk = new Milk(true);
+
+ @Produces
+ public Cheese getCheese() {
+ return new Cheese(true);
+ }
+}
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Food.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Food.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Food.java 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,11 @@
+package org.jboss.jsr299.tck.tests.extensions.container.event;
+
+class Food
+{
+ @SuppressWarnings("unused")
+ private boolean fresh;
+
+ public Food(boolean fresh) {
+ this.fresh = fresh;
+ }
+}
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Milk.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Milk.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Milk.java 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,9 @@
+package org.jboss.jsr299.tck.tests.extensions.container.event;
+
+class Milk extends Food
+{
+ public Milk(boolean fresh)
+ {
+ super(fresh);
+ }
+}
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/ProcessAnnotatedTypeObserver.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/ProcessAnnotatedTypeObserver.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/ProcessAnnotatedTypeObserver.java 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,49 @@
+package org.jboss.jsr299.tck.tests.extensions.container.event;
+
+import javax.enterprise.event.Observes;
+import javax.enterprise.inject.spi.Extension;
+import javax.enterprise.inject.spi.ProcessAnnotatedType;
+
+public class ProcessAnnotatedTypeObserver implements Extension
+{
+ private static ProcessAnnotatedType<Sheep> statelessSessionBeanEvent = null;
+ private static ProcessAnnotatedType<Cow> statefulSessionBeanEvent = null;
+ private static ProcessAnnotatedType<SheepInterceptor> sessionBeanInterceptorEvent = null;
+ private static ProcessAnnotatedType<Farm> managedBeanEvent = null;
+
+ public void observeStatelessSessionBean(@Observes ProcessAnnotatedType<Sheep> event) {
+ statelessSessionBeanEvent = event;
+ }
+
+ public void observeStatefulSessionBean(@Observes ProcessAnnotatedType<Cow> event) {
+ statefulSessionBeanEvent = event;
+ }
+
+ public void observeSessionBeanInterceptor(@Observes ProcessAnnotatedType<SheepInterceptor> event) {
+ sessionBeanInterceptorEvent = event;
+ }
+
+ public void observeManagedBean(@Observes ProcessAnnotatedType<Farm> event) {
+ managedBeanEvent = event;
+ }
+
+ public static ProcessAnnotatedType<Sheep> getStatelessSessionBeanEvent()
+ {
+ return statelessSessionBeanEvent;
+ }
+
+ public static ProcessAnnotatedType<Cow> getStatefulSessionBeanEvent()
+ {
+ return statefulSessionBeanEvent;
+ }
+
+ public static ProcessAnnotatedType<SheepInterceptor> getSessionBeanInterceptorEvent()
+ {
+ return sessionBeanInterceptorEvent;
+ }
+
+ public static ProcessAnnotatedType<Farm> getManagedBeanEvent()
+ {
+ return managedBeanEvent;
+ }
+}
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/ProcessBeanObserver.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/ProcessBeanObserver.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/ProcessBeanObserver.java 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,62 @@
+package org.jboss.jsr299.tck.tests.extensions.container.event;
+
+import javax.enterprise.event.Observes;
+import javax.enterprise.inject.spi.Extension;
+import javax.enterprise.inject.spi.ProcessManagedBean;
+import javax.enterprise.inject.spi.ProcessProducerField;
+import javax.enterprise.inject.spi.ProcessProducerMethod;
+import javax.enterprise.inject.spi.ProcessSessionBean;
+
+public class ProcessBeanObserver implements Extension
+{
+ private static ProcessManagedBean<Farm> processManagedBeanEvent = null;
+ private static ProcessSessionBean<Sheep> processStatelessSessionBeanEvent = null;
+ private static ProcessSessionBean<Cow> processStatefulSessionBeanEvent = null;
+ private static ProcessProducerField<Milk, Farm> processProducerFieldEvent = null;
+ private static ProcessProducerMethod<Cheese, Farm> processProducerMethodEvent = null;
+
+ public void observeProcessManagedBean(@Observes ProcessManagedBean<Farm> event) {
+ processManagedBeanEvent = event;
+ }
+
+ public void observeProcessStatelessSessionBean(@Observes ProcessSessionBean<Sheep> event) {
+ processStatelessSessionBeanEvent = event;
+ }
+
+ public void observeProcessStatefulSessionBean(@Observes ProcessSessionBean<Cow> event) {
+ processStatefulSessionBeanEvent = event;
+ }
+
+ public void observeProcessProduceField(@Observes ProcessProducerField<Milk, Farm> event) {
+ processProducerFieldEvent = event;
+ }
+
+ public void observeProcessProduceMethod(@Observes ProcessProducerMethod<Cheese, Farm> event) {
+ processProducerMethodEvent = event;
+ }
+
+ public static ProcessProducerField<Milk, Farm> getProcessProducerFieldEvent()
+ {
+ return processProducerFieldEvent;
+ }
+
+ public static ProcessManagedBean<Farm> getProcessManagedBeanEvent()
+ {
+ return processManagedBeanEvent;
+ }
+
+ public static ProcessSessionBean<Sheep> getProcessStatelessSessionBeanEvent()
+ {
+ return processStatelessSessionBeanEvent;
+ }
+
+ public static ProcessSessionBean<Cow> getProcessStatefulSessionBeanEvent()
+ {
+ return processStatefulSessionBeanEvent;
+ }
+
+ public static ProcessProducerMethod<Cheese, Farm> getProcessProducerMethodEvent()
+ {
+ return processProducerMethodEvent;
+ }
+}
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/ProcessInjectionTargetObserver.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/ProcessInjectionTargetObserver.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/ProcessInjectionTargetObserver.java 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,101 @@
+package org.jboss.jsr299.tck.tests.extensions.container.event;
+
+import javax.enterprise.event.Observes;
+import javax.enterprise.inject.spi.Extension;
+import javax.enterprise.inject.spi.ProcessInjectionTarget;
+
+public class ProcessInjectionTargetObserver implements Extension
+{
+ private static ProcessInjectionTarget<Sheep> statelessSessionBeanEvent = null;
+ private static ProcessInjectionTarget<Cow> statefulSessionBeanEvent = null;
+ private static ProcessInjectionTarget<SheepInterceptor> sessionBeanInterceptorEvent = null;
+ private static ProcessInjectionTarget<Farm> managedBeanEvent = null;
+
+ private static int event1Observed = 0;
+ private static int event2Observed = 0;
+ private static int event3Observed = 0;
+ private static int event4Observed = 0;
+ private static int event5Observed = 0;
+
+
+ public void observeStatelessSessionBean(@Observes ProcessInjectionTarget<Sheep> event) {
+ statelessSessionBeanEvent = event;
+ }
+
+ public void observeStatefulSessionBean(@Observes ProcessInjectionTarget<Cow> event) {
+ statefulSessionBeanEvent = event;
+ }
+
+ public void observeSessionBeanInterceptor(@Observes ProcessInjectionTarget<SheepInterceptor> event) {
+ sessionBeanInterceptorEvent = event;
+ }
+
+ public void observeManagedBean(@Observes ProcessInjectionTarget<Farm> event) {
+ managedBeanEvent = event;
+ }
+
+ public void observeEvent1(@Observes ProcessInjectionTarget<? super String> event) {
+ event1Observed++;
+ }
+
+ public void observeEvent2(@Observes ProcessInjectionTarget<? extends String> event) {
+ event2Observed++;
+ }
+
+ public void observeEvent3(@Observes ProcessInjectionTarget<String> event) {
+ event3Observed++;
+ }
+
+ public void observeEvent4(@Observes ProcessInjectionTarget<? super SheepLocal> event) {
+ event4Observed++;
+ }
+
+ public void observeEvent5(@Observes ProcessInjectionTarget<? extends SheepLocal> event) {
+ event5Observed++;
+ }
+
+ public static ProcessInjectionTarget<Sheep> getStatelessSessionBeanEvent()
+ {
+ return statelessSessionBeanEvent;
+ }
+
+ public static ProcessInjectionTarget<Cow> getStatefulSessionBeanEvent()
+ {
+ return statefulSessionBeanEvent;
+ }
+
+ public static ProcessInjectionTarget<SheepInterceptor> getSessionBeanInterceptorEvent()
+ {
+ return sessionBeanInterceptorEvent;
+ }
+
+ public static ProcessInjectionTarget<Farm> getManagedBeanEvent()
+ {
+ return managedBeanEvent;
+ }
+
+ public static int getEvent1Observed()
+ {
+ return event1Observed;
+ }
+
+ public static int getEvent2Observed()
+ {
+ return event2Observed;
+ }
+
+ public static int getEvent3Observed()
+ {
+ return event3Observed;
+ }
+
+ public static int getEvent4Observed()
+ {
+ return event4Observed;
+ }
+
+ public static int getEvent5Observed()
+ {
+ return event5Observed;
+ }
+}
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Sheep.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Sheep.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Sheep.java 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,13 @@
+package org.jboss.jsr299.tck.tests.extensions.container.event;
+
+import javax.ejb.Stateless;
+import javax.interceptor.Interceptors;
+
+@Stateless(name = "sheep")
+@Tame
+public class Sheep implements SheepLocal
+{
+ @Interceptors(Sheep.class)
+ public void baa() {
+ }
+}
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/SheepInterceptor.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/SheepInterceptor.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/SheepInterceptor.java 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,13 @@
+package org.jboss.jsr299.tck.tests.extensions.container.event;
+
+import javax.interceptor.AroundInvoke;
+import javax.interceptor.InvocationContext;
+
+public class SheepInterceptor
+{
+ @AroundInvoke
+ public Object intercept(InvocationContext invocation) throws Exception
+ {
+ return invocation.proceed();
+ }
+}
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/SheepLocal.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/SheepLocal.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/SheepLocal.java 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,9 @@
+package org.jboss.jsr299.tck.tests.extensions.container.event;
+
+import javax.ejb.Local;
+
+@Local
+public interface SheepLocal
+{
+ void baa();
+}
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Tame.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Tame.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/Tame.java 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,22 @@
+package org.jboss.jsr299.tck.tests.extensions.container.event;
+
+import static java.lang.annotation.ElementType.FIELD;
+import static java.lang.annotation.ElementType.METHOD;
+import static java.lang.annotation.ElementType.PARAMETER;
+import static java.lang.annotation.ElementType.TYPE;
+import static java.lang.annotation.RetentionPolicy.RUNTIME;
+
+import java.lang.annotation.Documented;
+import java.lang.annotation.Retention;
+import java.lang.annotation.Target;
+
+import javax.inject.Qualifier;
+
+@Target( { TYPE, METHOD, PARAMETER, FIELD })
+@Retention(RUNTIME)
+@Documented
+@Qualifier
+@interface Tame
+{
+
+}
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverRegistersException/AddDefinitionErrorTest.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverRegistersException/AddDefinitionErrorTest.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverRegistersException/AddDefinitionErrorTest.java 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,42 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed 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.
+ */
+package org.jboss.jsr299.tck.tests.extensions.container.event.broken.processBeanObserverRegistersException;
+
+import org.jboss.jsr299.tck.AbstractJSR299Test;
+import org.jboss.jsr299.tck.DefinitionError;
+import org.jboss.test.audit.annotations.SpecAssertion;
+import org.jboss.test.audit.annotations.SpecVersion;
+import org.jboss.testharness.impl.packaging.Artifact;
+import org.jboss.testharness.impl.packaging.ExpectedDeploymentException;
+import org.jboss.testharness.impl.packaging.IntegrationTest;
+import org.jboss.testharness.impl.packaging.Resource;
+import org.testng.annotations.Test;
+
+@Artifact
+(a)ExpectedDeploymentException(DefinitionError.class)
+@Resource(source = "javax.enterprise.inject.spi.Extension", destination = "WEB-INF/classes/META-INF/services/javax.enterprise.inject.spi.Extension")
+@IntegrationTest
+@SpecVersion(spec = "cdi", version = "20091018")
+public class AddDefinitionErrorTest extends AbstractJSR299Test
+{
+ @Test(groups = "ri-broken")
+ @SpecAssertion(section="11.5.8", id="h")
+ //WELD-223
+ public void testAddDefinitionError() {
+ assert false;
+ }
+}
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverRegistersException/ProcessBeanObserver.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverRegistersException/ProcessBeanObserver.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverRegistersException/ProcessBeanObserver.java 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,12 @@
+package org.jboss.jsr299.tck.tests.extensions.container.event.broken.processBeanObserverRegistersException;
+
+import javax.enterprise.event.Observes;
+import javax.enterprise.inject.spi.Extension;
+import javax.enterprise.inject.spi.ProcessBean;
+
+public class ProcessBeanObserver implements Extension
+{
+ public void observe(@Observes ProcessBean<Sheep> event) {
+ event.addDefinitionError(new RuntimeException());
+ }
+}
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverRegistersException/Sheep.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverRegistersException/Sheep.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverRegistersException/Sheep.java 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,6 @@
+package org.jboss.jsr299.tck.tests.extensions.container.event.broken.processBeanObserverRegistersException;
+
+class Sheep
+{
+
+}
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverThrowsException/ProcessBeanObserver.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverThrowsException/ProcessBeanObserver.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverThrowsException/ProcessBeanObserver.java 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,12 @@
+package org.jboss.jsr299.tck.tests.extensions.container.event.broken.processBeanObserverThrowsException;
+
+import javax.enterprise.event.Observes;
+import javax.enterprise.inject.spi.Extension;
+import javax.enterprise.inject.spi.ProcessBean;
+
+public class ProcessBeanObserver implements Extension
+{
+ public void observe(@Observes ProcessBean<Sheep> event) {
+ throw new RuntimeException();
+ }
+}
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverThrowsException/Sheep.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverThrowsException/Sheep.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverThrowsException/Sheep.java 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,6 @@
+package org.jboss.jsr299.tck.tests.extensions.container.event.broken.processBeanObserverThrowsException;
+
+class Sheep
+{
+
+}
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverThrowsException/ThrowExceptionInProcessBeanObserverTest.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverThrowsException/ThrowExceptionInProcessBeanObserverTest.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverThrowsException/ThrowExceptionInProcessBeanObserverTest.java 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,42 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed 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.
+ */
+package org.jboss.jsr299.tck.tests.extensions.container.event.broken.processBeanObserverThrowsException;
+
+import org.jboss.jsr299.tck.AbstractJSR299Test;
+import org.jboss.jsr299.tck.DefinitionError;
+import org.jboss.test.audit.annotations.SpecAssertion;
+import org.jboss.test.audit.annotations.SpecVersion;
+import org.jboss.testharness.impl.packaging.Artifact;
+import org.jboss.testharness.impl.packaging.ExpectedDeploymentException;
+import org.jboss.testharness.impl.packaging.IntegrationTest;
+import org.jboss.testharness.impl.packaging.Resource;
+import org.testng.annotations.Test;
+
+@Artifact
+(a)ExpectedDeploymentException(DefinitionError.class)
+@Resource(source = "javax.enterprise.inject.spi.Extension", destination = "WEB-INF/classes/META-INF/services/javax.enterprise.inject.spi.Extension")
+@IntegrationTest
+@SpecVersion(spec = "cdi", version = "20091018")
+public class ThrowExceptionInProcessBeanObserverTest extends AbstractJSR299Test
+{
+ @Test(groups = "ri-broken")
+ @SpecAssertion(section="11.5.8", id="hd")
+ //WELD-224
+ public void testProcessBeanObserverThrowsException() {
+ assert false;
+ }
+}
Added: cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverRegistersException/javax.enterprise.inject.spi.Extension
===================================================================
--- cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverRegistersException/javax.enterprise.inject.spi.Extension (rev 0)
+++ cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverRegistersException/javax.enterprise.inject.spi.Extension 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1 @@
+org.jboss.jsr299.tck.tests.extensions.container.event.broken.processBeanObserverRegistersException.ProcessBeanObserver
\ No newline at end of file
Added: cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverThrowsException/javax.enterprise.inject.spi.Extension
===================================================================
--- cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverThrowsException/javax.enterprise.inject.spi.Extension (rev 0)
+++ cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/event/broken/processBeanObserverThrowsException/javax.enterprise.inject.spi.Extension 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1 @@
+org.jboss.jsr299.tck.tests.extensions.container.event.broken.processBeanObserverThrowsException.ProcessBeanObserver
\ No newline at end of file
Added: cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/event/ejb-jar.xml
===================================================================
--- cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/event/ejb-jar.xml (rev 0)
+++ cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/event/ejb-jar.xml 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ejb-jar
+ xmlns="http://java.sun.com/xml/ns/javaee"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
+ http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
+ version="3.0">
+ <enterprise-beans>
+ <session>
+ <ejb-name>cow</ejb-name>
+ <business-local>org.jboss.jsr299.tck.tests.extensions.container.event.CowLocal</business-local>
+ <ejb-class>org.jboss.jsr299.tck.tests.extensions.container.event.Cow</ejb-class>
+ <session-type>Stateful</session-type>
+ <transaction-type>Container</transaction-type>
+ </session>
+ </enterprise-beans>
+</ejb-jar>
\ No newline at end of file
Added: cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/event/javax.enterprise.inject.spi.Extension
===================================================================
--- cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/event/javax.enterprise.inject.spi.Extension (rev 0)
+++ cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/extensions/container/event/javax.enterprise.inject.spi.Extension 2009-10-22 12:45:59 UTC (rev 4223)
@@ -0,0 +1,4 @@
+org.jboss.jsr299.tck.tests.extensions.container.event.ProcessBeanObserver
+org.jboss.jsr299.tck.tests.extensions.container.event.ProcessInjectionTargetObserver
+org.jboss.jsr299.tck.tests.extensions.container.event.ProcessAnnotatedTypeObserver
+
15 years, 1 month
Weld SVN: r4222 - cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/processBean.
by weld-commits@lists.jboss.org
Author: jharting
Date: 2009-10-22 08:14:28 -0400 (Thu, 22 Oct 2009)
New Revision: 4222
Modified:
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/processBean/ProcessBeanTest.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/processBean/ProcessSessionBeanTest.java
Log:
Matched tests to assertions
Modified: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/processBean/ProcessBeanTest.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/processBean/ProcessBeanTest.java 2009-10-22 12:02:04 UTC (rev 4221)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/processBean/ProcessBeanTest.java 2009-10-22 12:14:28 UTC (rev 4222)
@@ -33,7 +33,8 @@
@SpecAssertion(section = "11.5.8", id = "eda"),
@SpecAssertion(section = "11.5.8", id = "efa"),
@SpecAssertion(section = "11.5.8", id = "fa"),
- @SpecAssertion(section = "11.5.8", id = "l")
+ @SpecAssertion(section = "11.5.8", id = "l"),
+ @SpecAssertion(section = "12.3", id = "fa")
})
public void testProcessBeanEvent()
{
@@ -49,7 +50,8 @@
@SpecAssertion(section = "11.5.8", id = "efc"),
@SpecAssertion(section = "11.5.8", id = "fc"),
@SpecAssertion(section = "11.5.8", id = "i"),
- @SpecAssertion(section = "11.5.8", id = "j")
+ @SpecAssertion(section = "11.5.8", id = "j"),
+ @SpecAssertion(section = "12.3", id = "ha")
})
@Test
public void testProcessProducerMethodEvent()
@@ -71,7 +73,8 @@
@SpecAssertion(section = "11.5.8", id = "edd"),
@SpecAssertion(section = "11.5.8", id = "efd"),
@SpecAssertion(section = "11.5.8", id = "fd"),
- @SpecAssertion(section = "11.5.8", id = "n")
+ @SpecAssertion(section = "11.5.8", id = "n"),
+ @SpecAssertion(section = "12.3", id = "hb")
})
@Test
public void testProcessProducerFieldEvent()
Modified: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/processBean/ProcessSessionBeanTest.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/processBean/ProcessSessionBeanTest.java 2009-10-22 12:02:04 UTC (rev 4221)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/extensions/processBean/ProcessSessionBeanTest.java 2009-10-22 12:14:28 UTC (rev 4222)
@@ -38,7 +38,8 @@
@SpecAssertion(section = "11.5.8", id = "hb"),
@SpecAssertion(section = "11.5.8", id = "hc"),
@SpecAssertion(section = "11.5.8", id = "m"),
- @SpecAssertion(section = "11.5.8", id = "k")
+ @SpecAssertion(section = "11.5.8", id = "k"),
+ @SpecAssertion(section = "12.3", id = "fb")
})
public void testProcessSessionBeanEvent()
{
15 years, 1 month