move fast, all and broken test exclusions to profiles so that exclusions are merged correctly. revert to surefire 2.10 pending fix for http://jira.codehaus.org/browse/SUREFIRE-913. To run all tests use: -Dactivemq.tests=all

git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@1395978 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Gary Tully 2012-10-09 11:49:17 +00:00
parent 486e6374f2
commit 84ba54b24f
2 changed files with 518 additions and 580 deletions

View File

@ -446,15 +446,11 @@
</configuration> </configuration>
</plugin> </plugin>
<!-- Configure which tests are included/excuded -->
<plugin> <plugin>
<artifactId>maven-surefire-plugin</artifactId> <artifactId>maven-surefire-plugin</artifactId>
<configuration> <configuration>
<forkMode>pertest</forkMode> <forkMode>always</forkMode>
<childDelegation>false</childDelegation>
<useFile>true</useFile>
<argLine>${surefire.argLine}</argLine> <argLine>${surefire.argLine}</argLine>
<useManifestOnlyJar>false</useManifestOnlyJar>
<runOrder>alphabetical</runOrder> <runOrder>alphabetical</runOrder>
<systemProperties> <systemProperties>
@ -477,28 +473,195 @@
<includes> <includes>
<include>**/*Test.*</include> <include>**/*Test.*</include>
</includes> </includes>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.activemq.protobuf</groupId>
<artifactId>activemq-protobuf</artifactId>
<executions>
<execution>
<goals>
<goal>compile</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-clean-plugin</artifactId>
<configuration>
<filesets>
<fileset>
<directory>${basedir}/activemq-data</directory>
</fileset>
</filesets>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>package</id>
<phase>package</phase>
<configuration>
<tasks>
<echo>Deleting unwanted resources from the test-jar</echo>
<delete dir="${project.build.directory}/test-classes" verbose="true">
<include name="*.*" />
</delete>
</tasks>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
<execution>
<id>site</id>
<phase>site</phase>
<configuration>
<tasks>
<echo>Running the XSDDoc task</echo>
<taskdef name="xsddoc" classname="net.sf.xframe.xsddoc.Task" />
<mkdir dir="${basedir}/target/site/xsddoc" />
<xsddoc file="${basedir}/target/classes/activemq.xsd" out="${basedir}/target/site/xsddoc" doctitle="Apache ActiveMQ XML Schema Reference" header="&lt;a href='http://activemq.apache.org/'&gt;Apache ActiveMQ&lt;/a&gt;" footer="Copyright 2005-2012 (c) the &lt;a href='http://www.apache.org/'&gt;Apache Software Foundation&lt;/a&gt;" verbose="false" />
<!--
css="${basedir}/../etc/css/stylesheet.css"
-->
</tasks>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>xsddoc</groupId>
<artifactId>maven-xsddoc-plugin</artifactId>
<version>1.0</version>
</dependency>
</dependencies>
</plugin>
<!-- generate the attached tests jar -->
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<executions>
<execution>
<goals>
<goal>test-jar</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>javacc-maven-plugin</artifactId>
<executions>
<execution>
<phase>generate-sources</phase>
<configuration>
<sourceDirectory>${basedir}/src/main/grammar</sourceDirectory>
<outputDirectory>${basedir}/target/generated-javacc</outputDirectory>
<packageName>org.apache.activemq.selector</packageName>
</configuration>
<goals>
<goal>javacc</goal>
</goals>
</execution>
</executions>
</plugin>
<!-- disabled until the xbean 3.11.2 plugin is released -->
<!--
<plugin>
<groupId>org.apache.xbean</groupId>
<artifactId>maven-xbean-plugin</artifactId>
<version>${xbean-version}</version>
<executions>
<execution>
<phase>process-classes</phase>
<configuration>
<includes>
<include>${basedir}/../activemq-leveldb/src/main/scala</include>
</includes>
<strictXsdOrder>false</strictXsdOrder>
<namespace>http://activemq.apache.org/schema/core</namespace>
<schema>${basedir}/target/classes/activemq.xsd</schema>
<outputDir>${basedir}/target/classes</outputDir>
<generateSpringSchemasFile>false</generateSpringSchemasFile>
<excludedClasses>org.apache.activemq.broker.jmx.AnnotatedMBean,org.apache.activemq.broker.jmx.DestinationViewMBean</excludedClasses>
</configuration>
<goals>
<goal>mapping</goal>
</goals>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>com.thoughtworks.qdox</groupId>
<artifactId>qdox</artifactId>
<version>1.12</version>
</dependency>
</dependencies>
</plugin>
-->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>cobertura-maven-plugin</artifactId>
<configuration>
<check>
<branchRate>50</branchRate>
<lineRate>50</lineRate>
<haltOnFailure>true</haltOnFailure>
<totalBranchRate>50</totalBranchRate>
<totalLineRate>50</totalLineRate>
</check>
</configuration>
</plugin>
</plugins>
</build>
<profiles>
<profile>
<id>activemq.tests-all</id>
<activation>
<property>
<name>activemq.tests</name>
<value>all</value>
</property>
</activation>
<build>
<plugins>
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<excludes>
<exclude>**/DoSTest.*</exclude>
</excludes>
</configuration>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>activemq.exclude-broken-tests</id>
<activation>
<activeByDefault>true</activeByDefault>
<property>
<name>activemq.tests</name>
</property>
</activation>
<build>
<plugins>
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<excludes> <excludes>
<exclude>**/perf/SimpleDurableTopicTest.*</exclude>
<!-- These tests run too slow to execute as part of the unit tests -->
<exclude>**/TransactionNotStartedErrorTest.*</exclude>
<exclude>**/DefaultStoreBrokerTest.*</exclude>
<exclude>**/TcpTransportBrokerTest.*</exclude>
<exclude>**/activeio/*</exclude>
<!-- These are performance tests so take too long to run -->
<exclude>**/perf/*</exclude>
<!-- These are load tests so take too long to run -->
<exclude>**/load/*</exclude>
<!-- http://jira.activemq.org/jira/browse/AMQ-626 --> <!-- http://jira.activemq.org/jira/browse/AMQ-626 -->
<exclude>**/MultipleTestsWithSpringFactoryBeanTest.*</exclude> <exclude>**/MultipleTestsWithSpringFactoryBeanTest.*</exclude>
<exclude>**/MultipleTestsWithXBeanFactoryBeanTest.*</exclude> <exclude>**/MultipleTestsWithXBeanFactoryBeanTest.*</exclude>
<exclude>**/MultipleTestsWithSpringXBeanFactoryBeanTest.*</exclude> <exclude>**/MultipleTestsWithSpringXBeanFactoryBeanTest.*</exclude>
<!-- these seem to fail only in m2 -->
<!--<exclude>**/TransactedTopicMasterSlaveTest.*</exclude>-->
<!-- Multicast and UDP based tests fail on GBuild --> <!-- Multicast and UDP based tests fail on GBuild -->
<exclude>**/PeerTransportTest.*</exclude> <exclude>**/PeerTransportTest.*</exclude>
<exclude>**/MulticastTransportTest.*</exclude> <exclude>**/MulticastTransportTest.*</exclude>
@ -538,7 +701,6 @@
<exclude>**/vm/VMTransportBrokerTest.*</exclude> <exclude>**/vm/VMTransportBrokerTest.*</exclude>
<exclude>**/broker/MarshallingBrokerTest.*</exclude> <exclude>**/broker/MarshallingBrokerTest.*</exclude>
<exclude>**/AMQDeadlockTest3.*</exclude> <exclude>**/AMQDeadlockTest3.*</exclude>
<!-- https://issues.apache.org/activemq/browse/AMQ-2050 --> <!-- https://issues.apache.org/activemq/browse/AMQ-2050 -->
@ -548,6 +710,35 @@
<exclude>**/BrokerNetworkWithStuckMessagesTest.*</exclude> <exclude>**/BrokerNetworkWithStuckMessagesTest.*</exclude>
<exclude>**/DoSTest.*</exclude> <exclude>**/DoSTest.*</exclude>
</excludes>
</configuration>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>activemq.tests-quick</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<build>
<plugins>
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<excludes>
<exclude>**/perf/SimpleDurableTopicTest.*</exclude>
<!-- These tests run too slow to execute as part of the unit tests -->
<exclude>**/TransactionNotStartedErrorTest.*</exclude>
<exclude>**/DefaultStoreBrokerTest.*</exclude>
<exclude>**/TcpTransportBrokerTest.*</exclude>
<!-- These are performance tests so take too long to run -->
<exclude>**/perf/*</exclude>
<!-- These are load tests so take too long to run -->
<exclude>**/load/*</exclude>
<!-- Don't run the openwire encoding tests since the test and impls are code generated --> <!-- Don't run the openwire encoding tests since the test and impls are code generated -->
<exclude>org/apache/activemq/openwire/v*/**</exclude> <exclude>org/apache/activemq/openwire/v*/**</exclude>
@ -957,259 +1148,6 @@
</excludes> </excludes>
</configuration> </configuration>
</plugin> </plugin>
<plugin>
<groupId>org.apache.activemq.protobuf</groupId>
<artifactId>activemq-protobuf</artifactId>
<executions>
<execution>
<goals>
<goal>compile</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-clean-plugin</artifactId>
<configuration>
<filesets>
<fileset>
<directory>${basedir}/activemq-data</directory>
</fileset>
</filesets>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>package</id>
<phase>package</phase>
<configuration>
<tasks>
<echo>Deleting unwanted resources from the test-jar</echo>
<delete dir="${project.build.directory}/test-classes" verbose="true">
<include name="*.*" />
</delete>
</tasks>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
<execution>
<id>site</id>
<phase>site</phase>
<configuration>
<tasks>
<echo>Running the XSDDoc task</echo>
<taskdef name="xsddoc" classname="net.sf.xframe.xsddoc.Task" />
<mkdir dir="${basedir}/target/site/xsddoc" />
<xsddoc file="${basedir}/target/classes/activemq.xsd" out="${basedir}/target/site/xsddoc" doctitle="Apache ActiveMQ XML Schema Reference" header="&lt;a href='http://activemq.apache.org/'&gt;Apache ActiveMQ&lt;/a&gt;" footer="Copyright 2005-2012 (c) the &lt;a href='http://www.apache.org/'&gt;Apache Software Foundation&lt;/a&gt;" verbose="false" />
<!--
css="${basedir}/../etc/css/stylesheet.css"
-->
</tasks>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>xsddoc</groupId>
<artifactId>maven-xsddoc-plugin</artifactId>
<version>1.0</version>
</dependency>
</dependencies>
</plugin>
<!-- generate the attached tests jar -->
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<executions>
<execution>
<goals>
<goal>test-jar</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>javacc-maven-plugin</artifactId>
<executions>
<execution>
<phase>generate-sources</phase>
<configuration>
<sourceDirectory>${basedir}/src/main/grammar</sourceDirectory>
<outputDirectory>${basedir}/target/generated-javacc</outputDirectory>
<packageName>org.apache.activemq.selector</packageName>
</configuration>
<goals>
<goal>javacc</goal>
</goals>
</execution>
</executions>
</plugin>
<!-- disabled until the xbean 3.11.2 plugin is released -->
<!--
<plugin>
<groupId>org.apache.xbean</groupId>
<artifactId>maven-xbean-plugin</artifactId>
<version>${xbean-version}</version>
<executions>
<execution>
<phase>process-classes</phase>
<configuration>
<includes>
<include>${basedir}/../activemq-leveldb/src/main/scala</include>
</includes>
<strictXsdOrder>false</strictXsdOrder>
<namespace>http://activemq.apache.org/schema/core</namespace>
<schema>${basedir}/target/classes/activemq.xsd</schema>
<outputDir>${basedir}/target/classes</outputDir>
<generateSpringSchemasFile>false</generateSpringSchemasFile>
<excludedClasses>org.apache.activemq.broker.jmx.AnnotatedMBean,org.apache.activemq.broker.jmx.DestinationViewMBean</excludedClasses>
</configuration>
<goals>
<goal>mapping</goal>
</goals>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>com.thoughtworks.qdox</groupId>
<artifactId>qdox</artifactId>
<version>1.12</version>
</dependency>
</dependencies>
</plugin>
-->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>cobertura-maven-plugin</artifactId>
<configuration>
<check>
<branchRate>50</branchRate>
<lineRate>50</lineRate>
<haltOnFailure>true</haltOnFailure>
<totalBranchRate>50</totalBranchRate>
<totalLineRate>50</totalLineRate>
</check>
</configuration>
</plugin>
</plugins>
</build>
<profiles>
<profile>
<id>slow-tests</id>
<build>
<plugins>
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<!-- not ideal to have to duplicate the config but the excludes don't override otherwise -->
<executions>
<execution>
<id>default-test</id>
<phase>test</phase>
<goals>
<goal>test</goal>
</goals>
<configuration>
<forkMode>pertest</forkMode>
<childDelegation>false</childDelegation>
<useFile>true</useFile>
<argLine>${surefire.argLine}</argLine>
<useManifestOnlyJar>false</useManifestOnlyJar>
<runOrder>alphabetical</runOrder>
<systemProperties>
<property>
<name>org.apache.activemq.default.directory.prefix</name>
<value>target/</value>
</property>
</systemProperties>
<includes>
<include>**/*Test.*</include>
</includes>
<excludes>
<exclude>**/perf/SimpleDurableTopicTest.*</exclude>
<!-- These tests run too slow to execute as part of the unit tests -->
<exclude>**/TransactionNotStartedErrorTest.*</exclude>
<exclude>**/DefaultStoreBrokerTest.*</exclude>
<exclude>**/TcpTransportBrokerTest.*</exclude>
<exclude>**/activeio/*</exclude>
<!-- These are performance tests so take too long to run -->
<exclude>**/perf/*</exclude>
<!-- These are load tests so take too long to run -->
<exclude>**/load/*</exclude>
<!-- http://jira.activemq.org/jira/browse/AMQ-626 -->
<exclude>**/MultipleTestsWithSpringFactoryBeanTest.*</exclude>
<exclude>**/MultipleTestsWithXBeanFactoryBeanTest.*</exclude>
<exclude>**/MultipleTestsWithSpringXBeanFactoryBeanTest.*</exclude>
<!-- these seem to fail only in m2 -->
<!--<exclude>**/TransactedTopicMasterSlaveTest.*</exclude>-->
<!-- Multicast and UDP based tests fail on GBuild -->
<exclude>**/PeerTransportTest.*</exclude>
<exclude>**/MulticastTransportTest.*</exclude>
<exclude>**/MulticastNetworkTest.*</exclude>
<exclude>**/UnreliableUdpTransportTest.*</exclude>
<exclude>**/SslTransportBrokerTest.*</exclude>
<!-- this one is a little flaky and can fail on some platforms randomly -->
<exclude>**/QuickJournalRecoveryBrokerTest.*</exclude>
<exclude>**/QuickJournalXARecoveryBrokerTest.*</exclude>
<exclude>**/ZeroconfDiscoverTransportTest.*</exclude>
<!-- m2 tests failing since move from assembly -->
<exclude>**/QueueConsumerCloseAndReconnectTest.*</exclude>
<exclude>**/TwoBrokerMulticastQueueTest.*</exclude>
<!-- This test only works on machines which have ssh propertly configured -->
<exclude>**/SSHTunnelNetworkReconnectTest.*</exclude>
<!-- http://issues.apache.org/activemq/browse/AMQ-1027 -->
<exclude>**/FailoverConsumerTest.*</exclude>
<!-- The NIO implemenation is not working properly on OS X.. -->
<exclude>**/nio/**</exclude>
<exclude>**/NioQueueSubscriptionTest.*/</exclude>
<!-- A test used for memory profiling only. -->
<exclude>**/NetworkConnectionsCleanedupTest.*/**</exclude>
<!-- used just to test potential memory leaks manually -->
<exclude>**/JDBCTestMemory.*</exclude>
<exclude>**/amq1490/*</exclude>
<exclude>**/archive/*</exclude>
<exclude>**/NetworkFailoverTest.*/**</exclude>
<exclude>**/vm/VMTransportBrokerTest.*</exclude>
<exclude>**/broker/MarshallingBrokerTest.*</exclude>
<exclude>**/AMQDeadlockTest3.*</exclude>
<!-- https://issues.apache.org/activemq/browse/AMQ-2050 -->
<exclude>**/ProxyConnectorTest.*</exclude>
<!-- breaks hudson: disable till we get a chance to give it the time that it needs - http://hudson.zones.apache.org/hudson/job/ActiveMQ/org.apache.activemq$activemq-core/199/testReport/org.apache.activemq.network/BrokerNetworkWithStuckMessagesTest/testBrokerNetworkWithStuckMessages/ -->
<exclude>**/BrokerNetworkWithStuckMessagesTest.*</exclude>
<exclude>**/DoSTest.*</exclude>
<exclude>org/apache/activemq/broker/ft/DbRestartJDBCQueueTest.*</exclude>
</excludes>
</configuration>
</execution>
</executions>
</plugin>
</plugins> </plugins>
</build> </build>
</profile> </profile>

View File

@ -125,7 +125,7 @@
<!-- Maven Plugin Version for this Project --> <!-- Maven Plugin Version for this Project -->
<maven-bundle-plugin-version>2.3.7</maven-bundle-plugin-version> <maven-bundle-plugin-version>2.3.7</maven-bundle-plugin-version>
<maven-surefire-plugin-version>2.12.3</maven-surefire-plugin-version> <maven-surefire-plugin-version>2.10</maven-surefire-plugin-version>
<maven-antrun-plugin-version>1.3</maven-antrun-plugin-version> <maven-antrun-plugin-version>1.3</maven-antrun-plugin-version>
<maven-assembly-plugin-version>2.3</maven-assembly-plugin-version> <maven-assembly-plugin-version>2.3</maven-assembly-plugin-version>
<maven-release-plugin-version>2.2.1</maven-release-plugin-version> <maven-release-plugin-version>2.2.1</maven-release-plugin-version>