JavaFX on headless Jenkins
Richard Bair
richard.bair at oracle.com
Mon Jan 6 08:16:25 PST 2014
Hi Tom!
On Jan 4, 2014, at 12:57 PM, Tom Eugelink <tbee at tbee.org> wrote:
> I'm trying to run JavaFX UI tests using TestFX on a headless Jenkins server (Ubuntu / Debian). I've gotten to the point where the UI is actually started by Jenkins, but then the test fail with a "no suitable pipeline found". Any suggestions how to fix that?
This was one of my long-standing TODO items: have a “headless” glass that would allow us to run quantum / prism tests headless. However for running scene graph or UI control tests, you should be using the “StubToolkit” instead of QuantumToolkit. The StubToolkit is located in Graphics/src/test, so for using it for 3rd party tests (like JFXtras) you would need to jar up the classes produced during a test run of FX. Then just specify the stub toolkit via -Djavafx.toolkit=com.sun.javafx.pgstub.StubToolkit
Now, longer term I wanted to nuke the StubToolkit. If we had a headless Glass then we could test with Prism/Quantum directly instead of the stubs. But this isn’t straightforward so it hasn’t been attempted yet.
Hope that helps.
Richard
>
> :*test*
> Executing task ':test' (up-to-date check took 0.054 secs) due to:
> No history is available.
> Starting process 'Gradle Worker 1'. Working directory: /var/lib/jenkins/workspace/JFXtras8.0 Command: /usr/lib/jvm/jdk1.8.0-ea/bin/java -Djava.security.manager=jarjar.org.gradle.process.internal.child.BootstrapSecurityManager -Dfile.encoding=UTF-8 -ea -cp /var/lib/jenkins/.gradle/caches/1.9/workerMain/gradle-worker.jar jarjar.org.gradle.process.internal.launcher.GradleWorkerMain
> Successfully started process 'Gradle Worker 1'
> Gradle Worker 1 executing tests.
>
> jfxtras.labs.scene.control.test.ListSpinnerEditableTest > enterSelectValueByTyping STANDARD_ERROR
> Graphics Device initialization failed for : es2, sw
> Error initializing QuantumRenderer: no suitable pipeline found
> java.lang.RuntimeException: java.lang.RuntimeException: Error initializing QuantumRenderer: no suitable pipeline found
> at com.sun.javafx.tk.quantum.QuantumRenderer.getInstance(QuantumRenderer.java:300)
> at com.sun.javafx.tk.quantum.QuantumToolkit.init(QuantumToolkit.java:244)
> at com.sun.javafx.tk.Toolkit.getToolkit(Toolkit.java:179)
> at com.sun.javafx.application.PlatformImpl.startup(PlatformImpl.java:210)
> at com.sun.javafx.application.LauncherImpl.startToolkit(LauncherImpl.java:653)
> at com.sun.javafx.application.LauncherImpl.launchApplication1(LauncherImpl.java:678)
> at com.sun.javafx.application.LauncherImpl.access$000(LauncherImpl.java:56)
> at com.sun.javafx.application.LauncherImpl$1.run(LauncherImpl.java:158)
> at java.lang.Thread.run(Thread.java:744)
> Caused by: java.lang.RuntimeException: Error initializing QuantumRenderer: no suitable pipeline found
> at com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.init(QuantumRenderer.java:98)
> at com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.run(QuantumRenderer.java:128)
> ... 1 more
> Exception in thread "Thread-4" java.lang.RuntimeException: No toolkit found
> at com.sun.javafx.tk.Toolkit.getToolkit(Toolkit.java:191)
> at com.sun.javafx.application.PlatformImpl.startup(PlatformImpl.java:210)
> at com.sun.javafx.application.LauncherImpl.startToolkit(LauncherImpl.java:653)
> at com.sun.javafx.application.LauncherImpl.launchApplication1(LauncherImpl.java:678)
> at com.sun.javafx.application.LauncherImpl.access$000(LauncherImpl.java:56)
> at com.sun.javafx.application.LauncherImpl$1.run(LauncherImpl.java:158)
> at java.lang.Thread.run(Thread.java:744)
>
>
More information about the openjfx-dev
mailing list