geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tki...@apache.org
Subject svn commit: r1023017 - in /geronimo/devtools/eclipse-plugin/trunk/testsuite/launcher: build.xml pom.xml
Date Fri, 15 Oct 2010 16:54:56 GMT
Author: tkirby
Date: Fri Oct 15 16:54:56 2010
New Revision: 1023017

URL: http://svn.apache.org/viewvc?rev=1023017&view=rev
Log:
GERONIMODEVTOOLS-599 GERONIMODEVTOOLS-675 GERONIMODEVTOOLS-649 fix testsuite launching on
mac and simplify and refactor to eliminate duplicate code

Modified:
    geronimo/devtools/eclipse-plugin/trunk/testsuite/launcher/build.xml
    geronimo/devtools/eclipse-plugin/trunk/testsuite/launcher/pom.xml

Modified: geronimo/devtools/eclipse-plugin/trunk/testsuite/launcher/build.xml
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/testsuite/launcher/build.xml?rev=1023017&r1=1023016&r2=1023017&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/testsuite/launcher/build.xml (original)
+++ geronimo/devtools/eclipse-plugin/trunk/testsuite/launcher/build.xml Fri Oct 15 16:54:56
2010
@@ -24,7 +24,19 @@
  | @version $Rev$ $Date$
  |
  -->
-<project name="GEP Automated Testsuite Launcher">
+<project name="GEP Automated Testsuite Launcher" default="launch" >
+
+    <condition property="isMac" >
+        <os family="mac" />
+    </condition>
+
+    <condition property="isUnix" >
+        <os family="unix" />
+    </condition>
+
+    <condition property="isWindows" >
+        <os family="windows" />
+    </condition>
 
     <!--
      |
@@ -34,8 +46,14 @@
      -->
     <target name="init">
         <!-- Prompt to install aries tools manually -->
-        <input message="&#10;Free Aries Tools download URL is http://www.ibm.com/developerworks/rational/downloads/10/rationaldevtoolsforosgiapplications.html&#10;Please
install aries tools manually for eclipse under testsuite/launcher/eclipse and then press Enter
to continue..."/>
+        <input>
+&#10;
+Please install Aries tools manually for eclipse under testsuite/launcher/eclipse,
+&#10;
+Free Aries tools download URL is http://www.ibm.com/developerworks/rational/downloads/10/rationaldevtoolsforosgiapplications.html
 
+Press Enter to continue...
+        </input>
 
         <property name="eclipse-home" value="eclipse"/>
         <copy tofile="${eclipse-home}/eclipse/plugins/org.eclipse.equinox.launcher.jar">
@@ -48,57 +66,38 @@
         </copy>
     </target>
 
+    <target name="setOSproperties" >
+        <antcall target="mac" />
+        <antcall target="unix" />
+        <antcall target="windows" />
+    </target>
 
-    <!--
-     |
-     | Start Eclipse via the Equinox launcher (Windows)
-     |
-     -->
-    <target name="win32" depends="init" description="Start Equinox launcher on Windows">
-        <java classname="org.eclipse.equinox.launcher.Main"
-              failonerror="true"
-              fork="true">
-            <classpath>
-                <pathelement path="${eclipse-home}/eclipse/plugins/org.eclipse.equinox.launcher.jar"/>
-            </classpath>
-            <arg line="-data workspace" />
-            <arg line="-application org.eclipse.ant.core.antRunner"/>
-            <arg line="-file testsuite.xml"/>
-            <arg value="all"/>
-            <arg value="-Dos=win32"/>
-            <arg value="-Dws=win32"/>
-            <arg value="-Darch=x86"/>
-        </java>
+    <target name="mac" if="isMac" >
+        <property name="osName" value="mac" />
+        <property name="os_property" value="macosx" />
+        <property name="ws_property" value="cocoa" />
+    </target>
+    <target name="unix" if="isUnix" >
+        <property name="osName" value="unix" />
+        <property name="os_property" value="linux" />
+        <property name="ws_property" value="gtk" />
     </target>
 
-    <!--
-     |
-     | Start Eclipse via the Equinox launcher (Linux)
-     |
-     -->
-    <target name="linux" depends="init" description="Start Equinox launcher on Linux">
-        <java classname="org.eclipse.equinox.launcher.Main"
-              failonerror="true"
-              fork="true">
-            <classpath>
-                <pathelement path="${eclipse-home}/eclipse/plugins/org.eclipse.equinox.launcher.jar"/>
-            </classpath>
-            <arg line="-data workspace" />
-            <arg line="-application org.eclipse.ant.core.antRunner"/>
-            <arg line="-file testsuite.xml"/>
-            <arg value="all"/>
-            <arg value="-Dos=linux"/>
-            <arg value="-Dws=gtk"/>
-            <arg value="-Darch=x86"/>
-        </java>
+    <target name="windows" if="isWindows" >
+        <property name="osName" value="windows" />
+        <property name="os_property" value="win32" />
+        <property name="ws_property" value="win32" />
     </target>
 
     <!--
      |
-     | Start Eclipse via the Equinox launcher (Mac)
+     | Start Eclipse via the Equinox launcher
      |
      -->
-    <target name="macos" depends="init" description="Start Equinox launcher on Mac">
+    <target name="launch" depends="init, setOSproperties" description="Start Equinox launcher">
+        <echo>
+Launching Equinox on ${osName} with -Dos=${os_property} -Dws=${ws_property}
+        </echo>
         <java classname="org.eclipse.equinox.launcher.Main"
               failonerror="true"
               fork="true">
@@ -109,8 +108,8 @@
             <arg line="-application org.eclipse.ant.core.antRunner"/>
             <arg line="-file testsuite.xml"/>
             <arg value="all"/>
-            <arg value="-Dos=macosx"/>
-            <arg value="-Dws=carbon"/>
+            <arg value="-Dos=${os_property}"/>
+            <arg value="-Dws=${ws_property}"/>
             <arg value="-Darch=x86"/>
         </java>
     </target>

Modified: geronimo/devtools/eclipse-plugin/trunk/testsuite/launcher/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/testsuite/launcher/pom.xml?rev=1023017&r1=1023016&r2=1023017&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/testsuite/launcher/pom.xml (original)
+++ geronimo/devtools/eclipse-plugin/trunk/testsuite/launcher/pom.xml Fri Oct 15 16:54:56
2010
@@ -46,7 +46,6 @@
                         <configuration>
                             <tasks>
                                 <ant antfile="${basedir}/build.xml">
-                                    <target name="${eclipsePlatformFamily}"></target>
                                 </ant>
                             </tasks>
                         </configuration>
@@ -74,41 +73,5 @@
             <type>pom</type>
         </dependency>
     </dependencies>
-
-    <profiles>
-        <profile>
-            <id>windows</id>
-            <activation>
-                <os>
-                    <family>windows</family>
-                </os>
-            </activation>
-            <properties>
-                <eclipsePlatformFamily>win32</eclipsePlatformFamily>
-            </properties>
-        </profile>
-        <profile>
-            <id>unix</id>
-            <activation>
-                <os>
-                    <family>unix</family>
-                </os>
-            </activation>
-            <properties>
-                <eclipsePlatformFamily>linux</eclipsePlatformFamily>
-            </properties>
-        </profile>
-        <profile>
-            <id>mac</id>
-            <activation>
-                <os>
-                    <family>mac</family>
-                </os>
-            </activation>
-            <properties>
-                <eclipsePlatformFamily>macos</eclipsePlatformFamily>
-            </properties>
-        </profile>
-    </profiles>
                                                 
 </project>



Mime
View raw message