You are viewing a plain text version of this content. The canonical link for it is here.
Posted to surefire-commits@maven.apache.org by kr...@apache.org on 2011/04/20 10:21:42 UTC

svn commit: r1095317 - in /maven/surefire/trunk: maven-failsafe-plugin/src/site/apt/examples/inclusion-exclusion.apt.vm maven-surefire-plugin/src/site/apt/examples/inclusion-exclusion.apt.vm

Author: krosenvold
Date: Wed Apr 20 08:21:42 2011
New Revision: 1095317

URL: http://svn.apache.org/viewvc?rev=1095317&view=rev
Log:
o Added documentation about regex support in includes/excludes

Modified:
    maven/surefire/trunk/maven-failsafe-plugin/src/site/apt/examples/inclusion-exclusion.apt.vm
    maven/surefire/trunk/maven-surefire-plugin/src/site/apt/examples/inclusion-exclusion.apt.vm

Modified: maven/surefire/trunk/maven-failsafe-plugin/src/site/apt/examples/inclusion-exclusion.apt.vm
URL: http://svn.apache.org/viewvc/maven/surefire/trunk/maven-failsafe-plugin/src/site/apt/examples/inclusion-exclusion.apt.vm?rev=1095317&r1=1095316&r2=1095317&view=diff
==============================================================================
--- maven/surefire/trunk/maven-failsafe-plugin/src/site/apt/examples/inclusion-exclusion.apt.vm (original)
+++ maven/surefire/trunk/maven-failsafe-plugin/src/site/apt/examples/inclusion-exclusion.apt.vm Wed Apr 20 08:21:42 2011
@@ -126,4 +126,33 @@ Inclusions and Exclusions of Tests
   </build>
   [...]
 </project>
-+---+
\ No newline at end of file
++---+
+
+* Regular expression support
+
+  An include/exclude pattern can be an ant-style path expression, but
+  regular expressions are also supported through this syntax:
+
++---+
+<project>
+  [...]
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-surefire-plugin</artifactId>
+        <version>${project.version}</version>
+        <configuration>
+          <includes>
+            <include>%regex[.*[Cat|Dog].*Test.*]</include>
+          </includes>
+        </configuration>
+      </plugin>
+    </plugins>
+  </build>
+  [...]
+</project>
++---+
+
+  Note the syntax %regex[expr], where expr is the actual expression and the rest is just wrapping. Also
+  note that regex matches are done over .class files and not .java files.
\ No newline at end of file

Modified: maven/surefire/trunk/maven-surefire-plugin/src/site/apt/examples/inclusion-exclusion.apt.vm
URL: http://svn.apache.org/viewvc/maven/surefire/trunk/maven-surefire-plugin/src/site/apt/examples/inclusion-exclusion.apt.vm?rev=1095317&r1=1095316&r2=1095317&view=diff
==============================================================================
--- maven/surefire/trunk/maven-surefire-plugin/src/site/apt/examples/inclusion-exclusion.apt.vm (original)
+++ maven/surefire/trunk/maven-surefire-plugin/src/site/apt/examples/inclusion-exclusion.apt.vm Wed Apr 20 08:21:42 2011
@@ -96,3 +96,32 @@ Inclusions and Exclusions of Tests
   [...]
 </project>
 +---+
+
+* Regular expression support
+
+  An include/exclude pattern can be an ant-style path expression, but
+  regular expressions are also supported through this syntax:
+
++---+
+<project>
+  [...]
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-surefire-plugin</artifactId>
+        <version>${project.version}</version>
+        <configuration>
+          <includes>
+            <include>%regex[.*[Cat|Dog].*Test.*]</include>
+          </includes>
+        </configuration>
+      </plugin>
+    </plugins>
+  </build>
+  [...]
+</project>
++---+
+
+  Note the syntax %regex[expr], where expr is the actual expression and the rest is just wrapping. Also
+  note that regex matches are done over .class files and not .java files.
\ No newline at end of file