rpms/eclipse-testframework/devel eclipse-tests-libraryXml.patch, NONE, 1.1 eclipse-testframework.spec, 1.1, 1.2

Alexander Kurtakov akurtakov at fedoraproject.org
Mon Aug 31 08:58:14 UTC 2009


Author: akurtakov

Update of /cvs/pkgs/rpms/eclipse-testframework/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv7421/devel

Modified Files:
	eclipse-testframework.spec 
Added Files:
	eclipse-tests-libraryXml.patch 
Log Message:
- Move library.xml patch from eclipse srpm.

eclipse-tests-libraryXml.patch:
 library.xml |   77 ++++++++++++++++++++++++++++++++++++++++--------------------
 1 file changed, 52 insertions(+), 25 deletions(-)

--- NEW FILE eclipse-tests-libraryXml.patch ---
### Eclipse Workspace Patch 1.0
#P org.eclipse.test
Index: library.xml
===================================================================
RCS file: /cvsroot/eclipse/org.eclipse.test/library.xml,v
retrieving revision 1.33
diff -u -r1.33 library.xml
--- library.xml	13 Mar 2008 14:00:36 -0000	1.33
+++ library.xml	7 May 2009 18:49:56 -0000
@@ -6,13 +6,13 @@
 	</target>
 
 	<target name="init">
-		<!-- 
+		<!--
 			Parameters:
 				(Mandatory)
 				data-dir		- the directory for Eclipse to write its data
 				plugin-name		- the name of the plugin to test
 				classname		- the name of the test class
-				
+
 				(Optional - overrides defaults set in script)
 				vmargs			- a string containing arguments to pass to the VM.
 				extraVMargs		- allows separate setting of VM args from separate caller.
@@ -22,7 +22,7 @@
 				useEclipseExe	- property setting forces test to launch via eclipse executable.
 				junit-report-output - output directory for junit reports produced for specified classname.
 		-->
-		
+
 	  	<tstamp>
 	        <format property="TIMENOW" pattern="HHmmssSSSS"/>
 	    </tstamp>
@@ -33,25 +33,30 @@
 		<!--default launch target for launching tests-->
 		<property name="launchTarget" value="java-test" />
 		<property name="formatter" value="org.apache.tools.ant.taskdefs.optional.junit.XMLJUnitResultFormatter"/>
-	    
+
 		<!--default heap sizes when running performance tests-->
 	    <condition property="vmargs" value=" -Xms256M -Xmx256M">
 			<equals arg1="${test.target}" arg2="performance" />
 	    </condition>
+        <condition property="extraVMargs" value=" -Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=40000">
+                    <equals arg1="${debugTests}" arg2="true" />
+        </condition>
 		<property name="extraVMargs" value=""/>
 		<property name="plugin-path" value="" />
+		<property name="tmpresults" value="${eclipse-home}/tmpresults/" />
+		<property name="testhome" value="${eclipse-home}/testhome" />
 		<property name="timeout" value="7200000" />
-		<property name="test-output" value="${eclipse-home}/${classname}.xml" />
+		<property name="test-output" value="${tmpresults}/${classname}.xml" />
 		<property name="junit-report-output" value="${eclipse-home}/results" />
 		<mkdir dir="${junit-report-output}"/>
 	</target>
-	
+
 	<target name="core-test" description="Eclipse application used to launch HEADLESS plugin tests." depends="init">
 		<antcall target="${launchTarget}">
 			<param name="application" value="org.eclipse.test.coretestapplication"/>
 		</antcall>
 	</target>
-	
+
 	<target name="ui-test" description="Eclipse application used to launch UI plugin tests." depends="init">
 		<antcall target="${launchTarget}">
 			<param name="application" value="org.eclipse.test.uitestapplication"/>
@@ -60,13 +65,17 @@
 
 	<target name="java-test">
 		<!--default vm args-->
-		<property name="vmargs" value=" -Xms40m -Xmx256m"/>
-	  	
+		<property name="vmargs" value=" -Xms256m -Xmx1024m -XX:MaxPermSize=512m"/>
+		<delete failonerror="false" includeEmptyDirs="true">
+		  <fileset dir="${testhome}" includes="**/*"/>
+		</delete>
+		<mkdir dir="${testhome}"/>
+
 	  	<!--set default jvm to use for testing-->
-	   	<property name="jvm" value="${java.home}/bin/java" />  	
-	
+	   	<property name="jvm" value="${java.home}/bin/java" />
+
 		<echo message="Running ${classname}. Result file: ${junit-report-output}/${classname}.xml."/>
-		
+
 		<java fork="true" dir="." timeout="${timeout}" jvm="${jvm}" logError="true"
 			classname="org.eclipse.core.launcher.Main" output="${junit-report-output}/${classname}.txt">
 	        <classpath>
@@ -75,7 +84,7 @@
 	          	</fileset>
 	        </classpath>
 		    <arg line="-application ${application}"/>
-		    <arg line="-data ${data-dir}"/>
+		    <arg line="-data ${test-data-dir}"/>
 		    <arg line="formatter=${formatter},${test-output}"/>
 		    <arg line="-testPluginName ${plugin-name}"/>
 		    <arg line="-className ${classname}"/>
@@ -83,15 +92,31 @@
 		    <arg line="-ws ${ws}"/>
 		    <arg line="-arch ${arch}"/>
 		    <arg line="-consolelog"/>
+			<arg line="-clean"/>
+			<arg line="-Dswt.library.path=/usr/lib/eclipse"/>
+			<arg line="-Dsetup.override.vmArgs=Xms256m;Xmx1024m"/>
+			<arg line="-Dsetup.override.systemProperties=PLUGIN_PATH=${plugin-path};user.home=${testhome}"/>
 		    <jvmarg line="${vmargs} ${extraVMargs}"/>
-		    <sysproperty key="PLUGIN_PATH" value="${plugin-path}"/> 
+		    <sysproperty key="PLUGIN_PATH" value="${plugin-path}"/>
+			<sysproperty key="user.home" value="${testhome}"/>
+			<sysproperty key="swt.library.path" value="/usr/lib/eclipse"/>
+			<sysproperty key="setup.override.vmArgs" value="Xms256m;Xmx1024m"/>
+			<sysproperty key="setup.override.systemProperties" value="PLUGIN_PATH=${plugin-path};user.home=${testhome}"/>
+			<sysproperty key="sdk.tests.data.dir" value="${data-dir}"/>
+			<sysproperty key="org.eclipse.equinox.p2.reconciler.tests.platform.archive" value="${tmpresults}/eclipse-platform-archive.tar.gz"/>
+			<sysproperty key="osgi.configuration.area" value="${data-dir}"/>
 		</java>
 		<antcall target="collect-results" />
 	</target>
-	
-	<target name="eclipse-test" description="Runs the specified classname as a plug-in test.">		
+
+	<target name="eclipse-test" description="Runs the specified classname as a plug-in test.">
 		<property name="vmargs" value="-Xms256m -Xmx512m"/>
-		
+
+		<delete failonerror="false" includeEmptyDirs="true">
+		  <fileset dir="${testhome}" includes="**/*"/>
+		</delete>
+		<mkdir dir="${testhome}"/>
+
 		<!--use -consolelog if launching a headless test-->
 		<condition property="consolelog" value="-consolelog">
 			<equals arg1="${application}" arg2="org.eclipse.test.coretestapplication"/>
@@ -107,11 +132,11 @@
 			<isset property="jvm" />
 		</condition>
 		<property name="test-vm" value="" />
-		
+
 		<!--ensure executable has execute permission-->
 		<chmod file="${eclipse-home}/eclipse" perm="ugo+rx"/>
-		
-		
+
+
 		<echo message="Running ${classname}. Result file: ${junit-report-output}/${classname}.xml."/>
 
 		<exec executable="${eclipse-home}/eclipse" dir="${eclipse-home}" timeout="${timeout}" logError="true" failonerror="false" output="${junit-report-output}/${classname}.txt">
@@ -125,10 +150,12 @@
 			<arg line="--launcher.suppressErrors"/>
 			<arg line="${consolelog}"/>
 			<arg line="-vmargs ${vmargs} ${extraVMargs} -DPLUGIN_PATH=${plugin-path}"/>
+			<arg line="-Duser.home=${testhome}"/>
+			<arg line="-Dsetup.override.systemProperties=PLUGIN_PATH=${plugin-path};user.home=${testhome}"/>
 		</exec>
 		<antcall target="collect-results" />
 	</target>
-	
+
 	<target name="collect-results">
 		<dirname property="output-dir" file="${test-output}"/>
 		<basename property="output-file-name" file="${test-output}"/>
@@ -138,7 +165,7 @@
 			</fileset>
 		</junitreport>
 
-		<style style="${eclipse-home}/dropins/eclipse/plugins/org.eclipse.test/JUNIT.XSL"
+		<style style="${eclipse-home}/dropins/sdk/plugins/org.eclipse.test/JUNIT.XSL"
 			basedir="${junit-report-output}"
 			includes="${classname}.result.xml"
 			destdir="${junit-report-output}" />
@@ -153,13 +180,13 @@
 	<target name="collect">
 		<!--
 			This target can be used to aggragate test runs from multiple test suites into a single report.
-		
+
 			Parameters to this target:
 			includes		- the names of the files to include
 			output-file		- the name of the output file to produce
 		-->
-		<junitreport todir="." tofile="${output-file}">
-			<fileset dir=".">
+		<junitreport todir="${results}" tofile="${output-file}">
+			<fileset dir="${tmpresults}">
 				<include name="${includes}"/>
 			</fileset>
 		</junitreport>


Index: eclipse-testframework.spec
===================================================================
RCS file: /cvs/pkgs/rpms/eclipse-testframework/devel/eclipse-testframework.spec,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -p -r1.1 -r1.2
--- eclipse-testframework.spec	21 Aug 2009 18:41:24 -0000	1.1
+++ eclipse-testframework.spec	31 Aug 2009 08:58:14 -0000	1.2
@@ -4,7 +4,7 @@
 
 Name:           eclipse-testframework
 Version:        3.5.0
-Release:        2%{?dist}
+Release:        3%{?dist}
 Summary:        Eclipse Test Framework
 
 Group:          Development/Tools
@@ -15,6 +15,9 @@ Source0:        %{name}-fetched-src-%{ta
 Source1:        %{name}-fetch-src.sh
 # Remove win32 fragment from test feature
 Patch0:         eclipse-nowin32testfragment.patch
+# Some fixes for library.xml
+# FIXME:  submit upstream
+Patch1:        eclipse-tests-libraryXml.patch
 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
 BuildArch: noarch
@@ -32,6 +35,10 @@ Eclipse Test Framework. Used in conjunct
 %setup -q -n %{name}-fetched-src-%{tag}
 chmod -x org.eclipse.test-feature/*.html
 %patch0
+pushd org.eclipse.test
+%patch1
+popd
+sed -i "s:/usr/lib/eclipse:%{_libdir}/%{name}:" org.eclipse.test/library.xml
 
 mkdir orbitDeps
 pushd orbitDeps
@@ -64,6 +71,9 @@ popd
 %doc org.eclipse.test-feature/epl-v10.html
 
 %changelog
+* Mon Aug 31 2009 Alexander Kurtakov <akurtako at redhat.com> 3.5.0-3
+- Move library.xml patch from eclipse srpm.
+
 * Fri Aug 21 2009 Alexander Kurtakov <akurtako at redhat.com> 3.5.0-2
 - Fix non-standard-dir-perm.
 




More information about the scm-commits mailing list