Author: pgier
Date: Tue Jun 1 03:49:25 2010
New Revision: 949918
URL: http://svn.apache.org/viewvc?rev=949918&view=rev
Log:
[MANTRUN-140] Fix property name for testOutputDirectory and test for this in ITs
Modified:
maven/plugins/trunk/maven-antrun-plugin/src/it/properties-test/build.xml
maven/plugins/trunk/maven-antrun-plugin/src/it/properties-test/pom.xml
maven/plugins/trunk/maven-antrun-plugin/src/main/java/org/apache/maven/plugin/antrun/AbstractAntMojo.java
Modified:
maven/plugins/trunk/maven-antrun-plugin/src/it/properties-test/build.xml
URL:
http://svn.apache.org/viewvc/maven/plugins/trunk/maven-antrun-plugin/src/it/properties-test/build.xml?rev=949918&r1=949917&r2=949918&view=diff
==============================================================================
--- maven/plugins/trunk/maven-antrun-plugin/src/it/properties-test/build.xml
(original)
+++ maven/plugins/trunk/maven-antrun-plugin/src/it/properties-test/build.xml
Tue Jun 1 03:49:25 2010
@@ -13,7 +13,31 @@
<fail unless="junit:junit:jar" message="Property not set
\${junit:junit:jar}"/>
<echo message="maven.dependency.junit.junit.jar.path :
${maven.dependency.junit.junit.jar.path}"/>
<fail unless="maven.dependency.junit.junit.jar.path" message="Property not
set \${maven.dependency.junit.junit.jar.path}"/>
-
+
+ <property name="outputDir" location="./target/classes"/>
+ <echo message="outputDir: ${outputDir}"/>
+ <property name="outputDirProp"
location="${project.build.outputDirectory}"/>
+ <echo message="outputDirProp: ${outputDirProp}"/>
+ <fail message="Incorrect output dir property">
+ <condition>
+ <not>
+ <equals arg1="${outputDir}" arg2="${outputDirProp}"/>
+ </not>
+ </condition>
+ </fail>
+
+ <property name="testOutputDir" location="./target/test-stuff"/>
+ <echo message="testOutputDir ${testOutputDir}"/>
+ <property name="testOutputDirProp"
location="${project.build.testOutputDirectory}"/>
+ <echo message="testOutputDirProp: ${testOutputDirProp}"/>
+ <fail message="Incorrect test output dir prop">
+ <condition>
+ <not>
+ <equals arg1="${testOutputDir}" arg2="${testOutputDirProp}"/>
+ </not>
+ </condition>
+ </fail>
+
</target>
</project>
Modified: maven/plugins/trunk/maven-antrun-plugin/src/it/properties-test/pom.xml
URL:
http://svn.apache.org/viewvc/maven/plugins/trunk/maven-antrun-plugin/src/it/properties-test/pom.xml?rev=949918&r1=949917&r2=949918&view=diff
==============================================================================
--- maven/plugins/trunk/maven-antrun-plugin/src/it/properties-test/pom.xml
(original)
+++ maven/plugins/trunk/maven-antrun-plugin/src/it/properties-test/pom.xml Tue
Jun 1 03:49:25 2010
@@ -19,6 +19,7 @@
</dependencies>
<build>
+ <testOutputDirectory>target/test-stuff</testOutputDirectory>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
Modified:
maven/plugins/trunk/maven-antrun-plugin/src/main/java/org/apache/maven/plugin/antrun/AbstractAntMojo.java
URL:
http://svn.apache.org/viewvc/maven/plugins/trunk/maven-antrun-plugin/src/main/java/org/apache/maven/plugin/antrun/AbstractAntMojo.java?rev=949918&r1=949917&r2=949918&view=diff
==============================================================================
---
maven/plugins/trunk/maven-antrun-plugin/src/main/java/org/apache/maven/plugin/antrun/AbstractAntMojo.java
(original)
+++
maven/plugins/trunk/maven-antrun-plugin/src/main/java/org/apache/maven/plugin/antrun/AbstractAntMojo.java
Tue Jun 1 03:49:25 2010
@@ -289,7 +289,7 @@ public abstract class AbstractAntMojo
antProject.setProperty( ( propertyPrefix + "project.packaging" ),
mavenProject.getPackaging() );
antProject.setProperty( ( propertyPrefix + "project.build.directory"
), mavenProject.getBuild().getDirectory() );
antProject.setProperty( ( propertyPrefix +
"project.build.outputDirectory" ), mavenProject.getBuild().getOutputDirectory()
);
- antProject.setProperty( ( propertyPrefix +
"project.build.outputDirectory" ),
mavenProject.getBuild().getTestOutputDirectory() );
+ antProject.setProperty( ( propertyPrefix +
"project.build.testOutputDirectory" ),
mavenProject.getBuild().getTestOutputDirectory() );
antProject.setProperty( ( propertyPrefix +
"project.build.sourceDirectory" ), mavenProject.getBuild().getSourceDirectory()
);
antProject.setProperty( ( propertyPrefix +
"project.build.testSourceDirectory" ),
mavenProject.getBuild().getTestSourceDirectory() );