You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by jd...@apache.org on 2008/11/26 02:46:35 UTC
svn commit: r720705 - in /maven/components/branches/maven-2.1.x: build.xml
maven-integration-tests/pom.xml
Author: jdcasey
Date: Tue Nov 25 17:46:35 2008
New Revision: 720705
URL: http://svn.apache.org/viewvc?rev=720705&view=rev
Log:
adjusting the checkout directory for maven-integration-test to avoid hard-coding /tmp (since some java.io.tmpdir locations are /var/tmp, etc.)
Modified:
maven/components/branches/maven-2.1.x/build.xml
maven/components/branches/maven-2.1.x/maven-integration-tests/pom.xml
Modified: maven/components/branches/maven-2.1.x/build.xml
URL: http://svn.apache.org/viewvc/maven/components/branches/maven-2.1.x/build.xml?rev=720705&r1=720704&r2=720705&view=diff
==============================================================================
--- maven/components/branches/maven-2.1.x/build.xml (original)
+++ maven/components/branches/maven-2.1.x/build.xml Tue Nov 25 17:46:35 2008
@@ -35,8 +35,6 @@
<project default="all" basedir="." xmlns:artifact="urn:maven-artifact-ant">
- <property name="it.workdir.version" value="2.1.x"/>
-
<target name="initTaskDefs" unless="taskdefs.inited">
<xmlproperty file="pom.xml" prefix="pom.xml" />
<path id="maven-ant-tasks.classpath" path="maven-ant-tasks-2.0.8.jar"/>
@@ -57,7 +55,7 @@
<fail unless="maven.home" message="You must set the M2_HOME environment variable or specify a maven.home property to this Ant script"/>
</target>
- <target name="read-pom" depends="initTaskDefs,initLocalRepo" unless="pom.version">
+ <target name="read-poms" depends="initTaskDefs,initLocalRepo" unless="pom.version">
<copy file="pom.xml" tofile="dependencies.xml"/>
<replace file="${basedir}/dependencies.xml" token="<!--start-->" value="<!--"/>
<replace file="${basedir}/dependencies.xml" token="<!--end-->" value="-->"/>
@@ -65,6 +63,10 @@
<localRepository path="${maven.repo.local}"/>
</artifact:pom>
<delete file="${basedir}/dependencies.xml"/>
+
+ <artifact:pom file="${basedir}/maven-integration-tests/pom.xml" id="itPom">
+ <localRepository path="${maven.repo.local}"/>
+ </artifact:pom>
</target>
<target name="init" depends="isMavenHomeSet,initLocalRepo">
@@ -83,7 +85,7 @@
<delete dir="bootstrap"/>
</target>
- <target name="pull" depends="init, read-pom" unless="skip.pull">
+ <target name="pull" depends="init, read-poms" unless="skip.pull">
<property name="verbose" value="false"/>
<!-- Pull the dependencies that Maven needs to build -->
<artifact:dependencies pathId="pom.pathid" filesetId="pom.fileset" verbose="${verbose}" useScope="compile">
@@ -220,14 +222,20 @@
<target name="its-win32" if="its.win32">
<echo>Retrieving integration tests</echo>
- <exec dir="${basedir}/maven-integration-tests" executable="cmd">
+ <exec dir="${basedir}/${itPom.artifactId}" executable="cmd">
<arg value="/c"/>
<arg value="${maven.home}\bin\mvn.bat"/>
- <arg value="initialize"/>
+ <arg value="process-resources"/>
+ </exec>
+ <exec dir="${basedir}/${itPom.artifactId}/target/classes" executable="cmd">
+ <arg value="/c"/>
+ <arg value="${maven.home}\bin\mvn.bat"/>
+ <arg value="package"/>
</exec>
<echo>Running integration tests</echo>
- <exec failonerror="true" dir="/tmp/maven-integration-tests-${it.workdir.version}" executable="cmd">
+ <!-- Hard-coding to /tmp/ to avoid long path names that will make windows scream. -->
+ <exec failonerror="true" dir="${java.io.tmpdir}/${itPom.artifactId}-${itPom.version}" executable="cmd">
<arg value="/c"/>
<arg value="${maven.home}\bin\mvn.bat"/>
<arg value="-Prun-its"/>
@@ -238,13 +246,16 @@
<target name="its-unix" if="its.unix">
<echo>Retrieving integration tests</echo>
- <exec dir="${basedir}/maven-integration-tests" executable="${maven.home}/bin/mvn">
- <arg value="initialize"/>
+ <exec dir="${basedir}/${itPom.artifactId}" executable="${maven.home}/bin/mvn">
+ <arg value="process-resources"/>
+ </exec>
+ <exec dir="${basedir}/${itPom.artifactId}/target/classes" executable="${maven.home}/bin/mvn">
+ <arg value="package"/>
</exec>
<echo>Running integration tests</echo>
<!-- Hard-coding to /tmp/ to avoid long path names that will make windows scream. -->
- <exec failonerror="true" dir="/tmp/maven-integration-tests-${it.workdir.version}" executable="${maven.home}/bin/mvn">
+ <exec failonerror="true" dir="${java.io.tmpdir}/${itPom.artifactId}-${itPom.version}" executable="${maven.home}/bin/mvn">
<arg value="-Prun-its"/>
<arg value="clean"/>
<arg value="install"/>
@@ -259,7 +270,7 @@
<target name="with-its" depends="all,run-its"/>
- <target name="set-temp-maven-home" depends="read-pom">
+ <target name="set-temp-maven-home" depends="read-poms">
<property name="maven.home" value="${java.io.tmpdir}/apache-maven-${pom.version}"/>
<echo>Using temporary maven install directory: ${maven.home}</echo>
</target>
Modified: maven/components/branches/maven-2.1.x/maven-integration-tests/pom.xml
URL: http://svn.apache.org/viewvc/maven/components/branches/maven-2.1.x/maven-integration-tests/pom.xml?rev=720705&r1=720704&r2=720705&view=diff
==============================================================================
--- maven/components/branches/maven-2.1.x/maven-integration-tests/pom.xml (original)
+++ maven/components/branches/maven-2.1.x/maven-integration-tests/pom.xml Tue Nov 25 17:46:35 2008
@@ -11,7 +11,9 @@
<properties>
<integrationTestSVNDir>trunk</integrationTestSVNDir>
- <itDir>${pom.basedir}/tests</itDir>
+
+ <!-- Using java.io.tmpdir to avoid long path names that will make windows scream. -->
+ <itDir>${java.io.tmpdir}/${pom.artifactId}-${pom.version}</itDir>
</properties>
<profiles>
@@ -20,8 +22,7 @@
<activation>
<activeByDefault>true</activeByDefault>
<file>
- <!-- NOT INTERPOLATED. These values must be explicit. -->
- <exists>/tmp/maven-integration-tests-2.1.x/pom.xml</exists>
+ <exists>${itDir}/pom.xml</exists>
</file>
</activation>
<build>
@@ -31,7 +32,7 @@
<executions>
<execution>
<id>scm</id>
- <phase>initialize</phase>
+ <phase>package</phase>
<goals>
<goal>update</goal>
</goals>
@@ -45,8 +46,7 @@
<id>checkout</id>
<activation>
<file>
- <!-- NOT INTERPOLATED. These values must be explicit. -->
- <missing>/tmp/maven-integration-tests-2.1.x/pom.xml</missing>
+ <missing>${itDir}/pom.xml</missing>
</file>
</activation>
<build>
@@ -56,7 +56,7 @@
<executions>
<execution>
<id>scm</id>
- <phase>initialize</phase>
+ <phase>package</phase>
<goals>
<goal>checkout</goal>
</goals>
@@ -75,9 +75,7 @@
<version>1.1</version>
<configuration>
<connectionUrl>scm:svn:http://svn.apache.org/repos/asf/maven/core-integration-testing/${integrationTestSVNDir}</connectionUrl>
- <!-- Hard-coding to /tmp/ to avoid long path names that will make windows scream. -->
- <!-- NOT INTERPOLATED DURING PROFILE ACTIVATION, so making these values explicit throughout to avoid confusion. -->
- <checkoutDirectory>/tmp/maven-integration-tests-2.1.x</checkoutDirectory>
+ <checkoutDirectory>${itDir}</checkoutDirectory>
</configuration>
</plugin>
</plugins>