[webbeans-commits] Webbeans SVN: r1492 - tck/trunk/impl/src/main/java/org/jboss/jsr299/tck and 1 other directory.

webbeans-commits at lists.jboss.org webbeans-commits at lists.jboss.org
Wed Feb 11 19:59:38 EST 2009


Author: pete.muir at jboss.org
Date: 2009-02-11 19:59:38 -0500 (Wed, 11 Feb 2009)
New Revision: 1492

Removed:
   ri/trunk/jboss-tck-runner/tck-unit-tests.xml
Modified:
   ri/trunk/jboss-tck-runner/pom.xml
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/AbstractTest.java
Log:
some fixes to non-incontainer tests

Modified: ri/trunk/jboss-tck-runner/pom.xml
===================================================================
--- ri/trunk/jboss-tck-runner/pom.xml	2009-02-12 00:29:02 UTC (rev 1491)
+++ ri/trunk/jboss-tck-runner/pom.xml	2009-02-12 00:59:38 UTC (rev 1492)
@@ -43,7 +43,64 @@
    </dependencies>
    
    <build>
-      <plugins>         
+      <plugins>
+         <plugin>
+            <groupId>org.apache.maven.plugins</groupId>
+            <artifactId>maven-dependency-plugin</artifactId>
+            <executions>
+               <execution>
+                  <id>copy</id>
+                  <phase>generate-test-sources</phase>
+                  <goals>
+                     <goal>copy</goal>
+                  </goals>
+                  <configuration>
+                     <stripVersion>true</stripVersion>
+                     <artifactItems>
+                        <artifactItem>
+                           <groupId>org.jboss.jsr299.tck</groupId>
+                           <artifactId>jsr299-tck-impl</artifactId>
+                           <type>xml</type>
+                           <classifier>suite</classifier>
+                           <overWrite>true</overWrite>
+                        </artifactItem>
+                        <artifactItem>
+                           <groupId>org.jboss.webbeans</groupId>
+                           <artifactId>webbeans-porting-package</artifactId>
+                           <overWrite>true</overWrite>
+                           <outputDirectory>${project.build.directory}/dependency/lib</outputDirectory>
+                        </artifactItem>
+                     </artifactItems>
+                  </configuration>
+               </execution>
+            </executions>
+         </plugin>
+         <plugin>
+            <groupId>org.apache.maven.plugins</groupId>
+            <artifactId>maven-surefire-plugin</artifactId>
+            <configuration>
+               <suiteXmlFiles>
+                  <suiteXmlFile>${project.build.directory}/dependency/jsr299-tck-impl-${jsr299.tck.version}-suite.xml</suiteXmlFile>
+               </suiteXmlFiles>
+            </configuration>
+         </plugin>
+         <plugin>
+            <groupId>org.apache.maven.plugins</groupId>
+            <artifactId>maven-surefire-report-plugin</artifactId>
+            <executions>
+               <execution>
+                  <id>generate-test-report</id>
+                  <phase>test</phase>
+                  <goals>
+                     <goal>report-only</goal>
+                  </goals>
+               </execution>
+            </executions>
+            <configuration>
+               <outputDirectory>${project.build.directory}/surefire-reports</outputDirectory>
+               <outputName>test-report</outputName>
+            </configuration>
+         </plugin>
       </plugins>
    </build>
    
@@ -59,34 +116,10 @@
             <plugins>
                <plugin>
                   <groupId>org.apache.maven.plugins</groupId>
-                  <artifactId>maven-dependency-plugin</artifactId>
-                  <executions>
-                     <execution>
-                        <id>copy</id>
-                        <phase>generate-test-sources</phase>
-                        <goals>
-                           <goal>copy</goal>
-                        </goals>
-                        <configuration>
-                           <stripVersion>true</stripVersion>
-                           <artifactItems>
-                              <artifactItem>
-                                 <groupId>org.jboss.webbeans</groupId>
-                                 <artifactId>webbeans-porting-package</artifactId>
-                                 <overWrite>true</overWrite>
-                                 <outputDirectory>${project.build.directory}/dependency/lib</outputDirectory>
-                              </artifactItem>
-                           </artifactItems>
-                        </configuration>
-                     </execution>
-                  </executions>
-               </plugin>
-               <plugin>
-                  <groupId>org.apache.maven.plugins</groupId>
                   <artifactId>maven-surefire-plugin</artifactId>
                   <configuration>
                      <suiteXmlFiles>
-                        <suiteXmlFile>tck-unit-tests.xml</suiteXmlFile>
+                        <suiteXmlFile>${project.build.directory}/dependency/jsr299-tck-impl-${jsr299.tck.version}-suite.xml</suiteXmlFile>
                      </suiteXmlFiles>
                      <systemProperties>
                         <property>
@@ -107,70 +140,6 @@
             </plugins>
          </build>
       </profile>
-      <profile>
-         <id>unit-tests</id>
-         <activation>
-            <property>
-               <name>unit</name>
-               <value>true</value>
-            </property>
-            <activeByDefault>true</activeByDefault>
-         </activation>
-         <build>
-            <plugins>
-               <plugin>
-                  <groupId>org.apache.maven.plugins</groupId>
-                  <artifactId>maven-dependency-plugin</artifactId>
-                  <executions>
-                     <execution>
-                        <id>copy</id>
-                        <phase>generate-test-sources</phase>
-                        <goals>
-                           <goal>copy</goal>
-                        </goals>
-                        <configuration>
-                           <artifactItems>
-                              <artifactItem>
-                                 <groupId>org.jboss.jsr299.tck</groupId>
-                                 <artifactId>jsr299-tck-impl</artifactId>
-                                 <type>xml</type>
-                                 <classifier>suite</classifier>
-                                 <overWrite>true</overWrite>
-                              </artifactItem>
-                           </artifactItems>
-                        </configuration>
-                     </execution>
-                  </executions>
-               </plugin>
-               <plugin>
-                  <groupId>org.apache.maven.plugins</groupId>
-                  <artifactId>maven-surefire-plugin</artifactId>
-                  <configuration>
-                     <suiteXmlFiles>
-                        <suiteXmlFile>${project.build.directory}/dependency/jsr299-tck-impl-${jsr299.tck.version}-suite.xml</suiteXmlFile>
-                     </suiteXmlFiles>
-                  </configuration>
-               </plugin>
-               <plugin>
-                  <groupId>org.apache.maven.plugins</groupId>
-                  <artifactId>maven-surefire-report-plugin</artifactId>
-                  <executions>
-                     <execution>
-                        <id>generate-test-report</id>
-                        <phase>test</phase>
-                        <goals>
-                           <goal>report-only</goal>
-                        </goals>
-                     </execution>
-                  </executions>
-                  <configuration>
-                     <outputDirectory>${project.build.directory}/surefire-reports</outputDirectory>
-                     <outputName>test-report</outputName>
-                  </configuration>
-               </plugin>
-            </plugins>
-         </build>
-      </profile>
    </profiles>
 
 </project>

Deleted: ri/trunk/jboss-tck-runner/tck-unit-tests.xml
===================================================================
--- ri/trunk/jboss-tck-runner/tck-unit-tests.xml	2009-02-12 00:29:02 UTC (rev 1491)
+++ ri/trunk/jboss-tck-runner/tck-unit-tests.xml	2009-02-12 00:59:38 UTC (rev 1492)
@@ -1,45 +0,0 @@
-<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd" >
-
-<suite name="JSR-299 TCK" verbose="2"  >
-
-   <test name="JSR-299 TCK" >
-      <groups >
-         <run>
-<!--          
-            <exclude name="specialization" />
-            <exclude name="deployment" />
-            <exclude name="disposalMethod" />
-            
-            <exclude name="observerMethod" />
-            <exclude name="deferredEvent" />
-            <exclude name="ejb3" />
-            <exclude name="webservice" />
-            <exclude name="annotationDefinition" />
-            <exclude name="webbeansxml" />
-            <exclude name="el" />
-            <exclude name="jms" />
-            <exclude name="interceptors" />
-            <exclude name="decorators" />
-            <exclude name="servlet" />
-            
-            <exclude name="passivation" />
-            <exclude name="singletons" />
-            <exclude name="ejbjarxml" />
-            <exclude name="beanDestruction" />
-            <exclude name="commonAnnotations" />
--->
-            <exclude name="stub" />
-            <exclude name="broken" />
-            <exclude name="underInvestigation" />
-         </run>
-      </groups>
-      <!-- <packages>
-         <package name="org.jboss.jsr299.tck.unit" />         
-         <package name="org.jboss.jsr299.tck.integration" />
-      </packages>-->
-      <classes>
-         <class name="org.jboss.jsr299.tck.unit.definition.bean.BeanDefinitionTest" />
-      </classes>
-   </test>
-   
-</suite>
\ No newline at end of file

Modified: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/AbstractTest.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/AbstractTest.java	2009-02-12 00:29:02 UTC (rev 1491)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/AbstractTest.java	2009-02-12 00:59:38 UTC (rev 1492)
@@ -28,7 +28,6 @@
 import org.jboss.jsr299.tck.impl.packaging.ArtifactGenerator;
 import org.jboss.jsr299.tck.impl.packaging.jsr299.TCKArtifactDescriptor;
 import org.jboss.jsr299.tck.impl.util.MockCreationalContext;
-import org.jboss.jsr299.tck.spi.StandaloneContainers;
 import org.testng.IHookCallBack;
 import org.testng.IHookable;
 import org.testng.ITestResult;
@@ -88,7 +87,6 @@
    }
    
    protected Manager manager;
-   private StandaloneContainers containers;
    private TCKArtifactDescriptor artifact;
    private Configuration configuration;
    
@@ -119,7 +117,7 @@
       {
          ArtifactGenerator generator = new ArtifactGenerator(configuration);
          artifact = generator.createArtifact(this.getClass());
-         if (!(configuration.isStandalone() && artifact.isUnit()))
+         if (artifact != null && !(configuration.isStandalone() && artifact.isUnit()))
          {
             configuration.getContainers().deploy(artifact.getJar(), artifact.getDefaultName());
          }
@@ -131,22 +129,22 @@
    {      
       if (configuration.isStandalone() && !isInContainer())
       {
-         containers = configuration.getStandaloneContainers();
          if (artifact != null)
          {
             Set<Class<?>> classes = artifact.getClasses();
             if (getEnabledDeploymentTypes().size() > 0)
             {
-               manager = containers.deploy(getEnabledDeploymentTypes(), classes.toArray(EMPTY_CLASS_ARRAY));
+               manager = configuration.getStandaloneContainers().deploy(getEnabledDeploymentTypes(), classes.toArray(EMPTY_CLASS_ARRAY));
             }
             else
             {
-               manager = containers.deploy(classes.toArray(EMPTY_CLASS_ARRAY));
+               manager = configuration.getStandaloneContainers().deploy(classes.toArray(EMPTY_CLASS_ARRAY));
             }
          }
          else
          {
             deployBeans();
+            manager = ConfigurationImpl.get().getManagers().getManager();
          }
          if (getEnabledDeploymentTypes().size() > 0)
          {
@@ -168,7 +166,7 @@
    @AfterClass
    public void afterClass() throws IOException
    {
-      if (!(configuration.isStandalone() && artifact.isUnit()) && !isInContainer())
+      if (artifact != null&& !(configuration.isStandalone() && artifact.isUnit()) && !isInContainer())
       {
          configuration.getContainers().undeploy(artifact.getDefaultName());
       }
@@ -211,11 +209,11 @@
    {
       if (getEnabledDeploymentTypes().size() > 0)
       {
-         manager = containers.deploy(getEnabledDeploymentTypes(), classes);
+         manager = configuration.getStandaloneContainers().deploy(getEnabledDeploymentTypes(), classes);
       }
       else
       {
-         manager = containers.deploy(classes);
+         manager = configuration.getStandaloneContainers().deploy(classes);
       }
    }
 




More information about the weld-commits mailing list