maven-surefire-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From krosenv...@apache.org
Subject svn commit: r1102431 - /maven/surefire/trunk/maven-surefire-plugin/src/site/apt/examples/junit.apt.vm
Date Thu, 12 May 2011 19:16:15 GMT
Author: krosenvold
Date: Thu May 12 19:16:14 2011
New Revision: 1102431

URL: http://svn.apache.org/viewvc?rev=1102431&view=rev
Log:
o Further updated docs on security manager

Modified:
    maven/surefire/trunk/maven-surefire-plugin/src/site/apt/examples/junit.apt.vm

Modified: maven/surefire/trunk/maven-surefire-plugin/src/site/apt/examples/junit.apt.vm
URL: http://svn.apache.org/viewvc/maven/surefire/trunk/maven-surefire-plugin/src/site/apt/examples/junit.apt.vm?rev=1102431&r1=1102430&r2=1102431&view=diff
==============================================================================
--- maven/surefire/trunk/maven-surefire-plugin/src/site/apt/examples/junit.apt.vm (original)
+++ maven/surefire/trunk/maven-surefire-plugin/src/site/apt/examples/junit.apt.vm Thu May
12 19:16:14 2011
@@ -172,7 +172,7 @@ else
       <plugin>
         <groupId>org.apache.maven.plugins</groupId>
         <artifactId>maven-surefire-plugin</artifactId>
-        <version>${surefire.version}</version>
+        <version>${project.version}</version>
         <configuration>
           <systemPropertyVariables>
             <surefire.security.manager>java.lang.SecurityManager</surefire.security.manager>
@@ -182,4 +182,25 @@ else
 [...]
 +---+
 
+* Using a security manager (All providers)
+
+    Alternatively you can define a policy file that allows all providers to run with surefire
+    and send them using the argLine parameter and two system properties;
+
++---+
+[...]
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-surefire-plugin</artifactId>
+        <version>${project.version}</version>
+        <configuration>
+          <argLine>-Djava.security.manager -Djava.security.policy=${basedir}/src/test/resources/java.policy</argLine>
+        </configuration>
+      </plugin>
+[...]
++---+
+
+  The disadvantage of this solution is that the policy changes will affect the tests too,
which make the
+  security environment less realistic.
+
   For more information on JUnit, see the {{{http://www.junit.org}JUnit web site}}.



Mime
View raw message