aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorReinier Zwitserloot <r.zwitserloot@projectlombok.org>2023-01-12 01:37:00 +0100
committerReinier Zwitserloot <r.zwitserloot@projectlombok.org>2023-01-12 01:37:00 +0100
commitf090e50d0d5d75c121b6170927b1e776160eb37d (patch)
tree92bb1d45e1f80ff8cb321124343e17a449c8250a
parent073ec78dd523e6108f18325f321204912b311f26 (diff)
downloadlombok-f090e50d0d5d75c121b6170927b1e776160eb37d.tar.gz
lombok-f090e50d0d5d75c121b6170927b1e776160eb37d.tar.bz2
lombok-f090e50d0d5d75c121b6170927b1e776160eb37d.zip
[tests] testing eclipse-full works on more platforms.
only worked on linux-x86_64, now it should work on more os+arch combos
-rw-r--r--buildScripts/setup.ant.xml22
-rw-r--r--buildScripts/tests.ant.xml6
2 files changed, 27 insertions, 1 deletions
diff --git a/buildScripts/setup.ant.xml b/buildScripts/setup.ant.xml
index 87a3593a..0531a392 100644
--- a/buildScripts/setup.ant.xml
+++ b/buildScripts/setup.ant.xml
@@ -40,6 +40,26 @@ This buildfile is part of projectlombok.org. It sets up the build itself.
<available file="${rtstubs18.loc}" property="rtstubs18.available" />
<property name="ssh.configuration.file" location="ssh.configuration" />
+ <condition property="os.specific.native-swt-lib" value="org.eclipse.swt.gtk.linux.aarch64">
+ <os name="Linux" arch="aarch64" />
+ </condition>
+ <condition property="os.specific.native-swt-lib" value="org.eclipse.swt.gtk.linux.x86_64">
+ <os name="Linux" />
+ </condition>
+ <condition property="os.specific.native-swt-lib" value="org.eclipse.swt.cocoa.macosx.aarch64">
+ <os name="Mac OS X" arch="aarch64" />
+ </condition>
+ <condition property="os.specific.native-swt-lib" value="org.eclipse.swt.cocoa.macosx.x86_64">
+ <os name="Mac OS X" />
+ </condition>
+ <condition property="os.specific.native-swt-lib" value="org.eclipse.swt.win32.win32.aarch64">
+ <os family="windows" arch="aarch64" />
+ </condition>
+ <condition property="os.specific.native-swt-lib" value="org.eclipse.swt.win32.win32.x86_64">
+ <os family="windows" />
+ </condition>
+ <fail unless="os.specific.native-swt-lib">Full eclipse testing requires downloading a native SWT binding. This script knows how to download for OS = [mac, linux, or windows] and architecture = [aarch64 or x86-64]. You have something different, you unique snowflake you. Your OS: "${os.name}", Your arch: "${os.arch}".</fail>
+
<target name="-setup.ssh.ask">
<property file="${ssh.configuration.file}" />
<fail>
@@ -312,7 +332,7 @@ This buildfile is part of projectlombok.org. It sets up the build itself.
<arg value="org.eclipse.osgi.util" />
<arg value="org.eclipse.search" />
<arg value="org.eclipse.swt" />
- <arg value="org.eclipse.swt.gtk.linux.x86_64" />
+ <arg value="${os.specific.native-swt-lib}" />
<arg value="org.eclipse.team.core" />
<arg value="org.eclipse.team.ui" />
<arg value="org.eclipse.text" />
diff --git a/buildScripts/tests.ant.xml b/buildScripts/tests.ant.xml
index f20f76ae..d34e1f82 100644
--- a/buildScripts/tests.ant.xml
+++ b/buildScripts/tests.ant.xml
@@ -222,9 +222,15 @@ This buildfile is part of projectlombok.org. It takes care of compiling and runn
</fileset>
</path>
<echo>Running EclipseTests on eclipse-@{version} on JVM${ant.java.version}</echo>
+ <condition property="os.specific.firstThread" value="-XstartOnFirstThread">
+ <os name="Mac OS X" />
+ </condition>
+ <!-- On Mac OS X, -XstartOnFirstThread is required, on other OSes, the JVM doesn't recognize the option. -showversion serves as a no-op -->
+ <property name="os.specific.firstThread" value="-showversion" />
<junit haltonfailure="yes" fork="true" forkmode="once">
<formatter classname="lombok.ant.SimpleTestFormatter" usefile="false" unless="tests.quiet" />
<jvmarg value="-javaagent:dist/lombok.jar" />
+ <jvmarg value="${os.specific.firstThread}" />
<jvmarg value="-Dlombok.testenv=testenv/eclipse-@{version}" />
<classpath refid="cp.eclipse-@{version}" />
<classpath location="build/ant" />