ctf: Restore the downloading of the ctf-testsuite
authorAlexandre Montplaisir <alexmonthy@voxpopuli.im>
Sun, 1 Nov 2015 04:15:17 +0000 (00:15 -0400)
committerAlexandre Montplaisir <alexmonthy@voxpopuli.im>
Wed, 18 Nov 2015 22:28:23 +0000 (17:28 -0500)
When we migrated to using the tracecompass-test-traces, we also stopped
downloading the ctf-testsuite using git. However those are not part of
tracecompass-test-traces. Oops!

Somehow the tests didn't complain so far, but it'd be better if they
actually ran.

Change-Id: Id6b81698bf8e85d840819db8505a95f57a51685c
Signed-off-by: Alexandre Montplaisir <alexmonthy@voxpopuli.im>
Reviewed-on: https://git.eclipse.org/r/59438
Reviewed-by: Hudson CI
Reviewed-by: Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
Tested-by: Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
ctf/org.eclipse.tracecompass.ctf.core.tests/pom.xml
ctf/org.eclipse.tracecompass.ctf.core.tests/traces/.gitignore
ctf/org.eclipse.tracecompass.ctf.core.tests/traces/get-traces.xml

index 59677f0d4f3995866984e3e6ac83b3dce7e17451..7ba751f45f519a5066d4ee1eaa1d8bff553b290b 100644 (file)
   <version>1.0.0-SNAPSHOT</version>
   <packaging>eclipse-test-plugin</packaging>
 
+  <properties>
+    <ctfTestSuiteCommit>0f8beba86ae551f42adeb81d1bfddd5645f31013</ctfTestSuiteCommit>
+  </properties>
+
   <!-- Do not download the test traces if "maven.test.skip" is set -->
   <profiles>
     <profile>
@@ -45,6 +49,7 @@
                 <phase>pre-integration-test</phase>
                 <configuration>
                   <target>
+                    <property name="ctf-test-suite-commit" value="${ctfTestSuiteCommit}"/>
                     <ant antfile="get-traces.xml" dir="traces" />
                   </target>
                 </configuration>
@@ -83,6 +88,7 @@
             <phase>clean</phase>
             <configuration>
               <filesets>
+                <fileset><directory>traces/ctf-testsuite</directory></fileset>
                 <fileset><directory>traces/synctraces</directory></fileset>
               </filesets>
             </configuration>
index 125deff3ef25ce135850192c364c42db9f488840..e20c91fabd56d10e0c7d1e19a90d0b4b9623bffe 100644 (file)
@@ -1,4 +1,5 @@
 *.gz
 *.tar
+ctf-testsuite/
 synctraces/
 synthetic-trace/
index 74d8dd2a9a2fd0762a1aa4754df7b27a0b834126..0ff205a39e0c2cfa1aa48d555f1373c80930f684 100644 (file)
     <target name="deleteFailedCheckSumTraces"/>
   </antcall>
   <antcall target="downloadTraceFiles"/>
+  <exec executable = "git" failifexecutionfails="false" timeout="20000">
+    <arg value = "clone"/>
+    <arg value = "https://github.com/efficios/ctf-testsuite.git"/>
+  </exec>
+  <condition property="testSuiteExists">
+    <and>
+      <available file="ctf-testsuite" type="dir"/>
+    </and>
+  </condition>
+  <antcall target="pullTestSuite"/>
   <condition property="tracesExist">
     <and>
       <available file="synctraces.tar.gz" />
   <get ignoreerrors="true" maxtime="60" skipexisting="true" dest="synctraces.tar.gz" src="http://archive.eclipse.org/tracecompass/test-traces/ctf/synctraces.tar.gz" />
 </target>
 
+<target name="pullTestSuite" if="testSuiteExists">
+  <!-- Update the local 'master' branch -->
+  <exec executable = "git" failifexecutionfails="false" dir="ctf-testsuite" timeout="20000">
+    <arg value = "checkout"/>
+    <arg value = "master"/>
+  </exec>
+  <exec executable = "git" failifexecutionfails="false" dir="ctf-testsuite" timeout="20000">
+    <arg value = "pull"/>
+  </exec>
+
+  <!-- Checkout the commit requested by the current build -->
+  <exec executable = "git" failifexecutionfails="false" dir="ctf-testsuite" timeout="20000">
+    <arg value = "checkout"/>
+    <arg value = "${ctf-test-suite-commit}"/>
+  </exec>
+</target>
+
 <target name="extractTraces" if="tracesExist">
     <antcall>
       <target name="checkAnyTraceExists"/>
This page took 0.025759 seconds and 5 git commands to generate.