Integrated: 8356687: [TestBug] SWT tests do not run on macOS
Jayathirth D V
jdv at openjdk.org
Wed Sep 10 04:38:34 UTC 2025
On Tue, 9 Sep 2025 10:30:12 GMT, Jayathirth D V <jdv at openjdk.org> wrote:
> We have enabled swt tests under [JDK-8169285](https://bugs.openjdk.org/browse/JDK-8169285) but they were disabled on macOS as they throw below exception :
>
>
> FXCanvasScaledTest STANDARD_OUT
> ***WARNING: Display must be created on main thread due to Cocoa restrictions. Use vmarg -XstartOnFirstThread
>
> FXCanvasScaledTest > initializationError FAILED
> org.eclipse.swt.SWTException: Invalid thread access
>
>
> Using `-XstartOnFirstThread` flag in gradle was not reliable and the issue was tracked under https://issues.gradle.org/browse/GRADLE-3290 and later under https://github.com/gradle/gradle/issues/864. This gradle issue is resolved and we can use `-XstartOnFirstThread` and enable SWT tests on macOS.
>
> With `-XstartOnFirstThread`, SWT tests run fine on macOS.
This pull request has now been integrated.
Changeset: 682d7682
Author: Jayathirth D V <jdv at openjdk.org>
URL: https://git.openjdk.org/jfx/commit/682d768244f1d290f0a7625437b0e72e74aae365
Stats: 5 lines in 1 file changed: 3 ins; 0 del; 2 mod
8356687: [TestBug] SWT tests do not run on macOS
Reviewed-by: kcr, angorya
-------------
PR: https://git.openjdk.org/jfx/pull/1888
More information about the openjfx-dev
mailing list