-
Bug
-
Resolution: Cannot Reproduce
-
P3
-
None
-
jfx11
ADDITIONAL SYSTEM INFORMATION :
jdk: OpenJDK11U-jdk_x64_windows_hotspot_11.0.10_9
javafx version: 11.0.2
monocle version: jdk-11+26
testfx version:4.0.16
cucumber-java:4.2.0
JVM parameters:
-Dtestfx.robot=glass
-Dglass.platform=Monocle
-Dmonocle.platform=Headless
-Dprism.order=sw
-Dprism.text=t2k
A DESCRIPTION OF THE PROBLEM :
This bug also reported at https://github.com/TestFX/Monocle/issues/83
As part of Test Automation, I am running JavaFX in Headless with Monocle platform, While running tests, I want to capture screenshots intermittently to prepare run report.
following code throws exception.
public static WritableImage takeScreenshot(final GlassRobot robot) {
final Rectangle2D bounds = Screen.getPrimary().getVisualBounds();
final int width = (int) bounds.getWidth();
final int height = (int) bounds.getHeight();
final int x = (int) bounds.getMinX();
final int y = (int) bounds.getMinY();
return robot.getScreenCapture(null, x, y, width, height, false);
}
Expected result: screenhsot captured
Actual result: java.lang.UnsupportedOperationException
at java.base/java.nio.IntBuffer.array(IntBuffer.java:1049)
at com.sun.glass.ui.monocle.MonocleRobot.getScreenCapture(MonocleRobot.java:209)
at com.sun.glass.ui.GlassRobot.getScreenCapture(GlassRobot.java:200)
REGRESSION : Last worked in version 8
FREQUENCY : always
jdk: OpenJDK11U-jdk_x64_windows_hotspot_11.0.10_9
javafx version: 11.0.2
monocle version: jdk-11+26
testfx version:4.0.16
cucumber-java:4.2.0
JVM parameters:
-Dtestfx.robot=glass
-Dglass.platform=Monocle
-Dmonocle.platform=Headless
-Dprism.order=sw
-Dprism.text=t2k
A DESCRIPTION OF THE PROBLEM :
This bug also reported at https://github.com/TestFX/Monocle/issues/83
As part of Test Automation, I am running JavaFX in Headless with Monocle platform, While running tests, I want to capture screenshots intermittently to prepare run report.
following code throws exception.
public static WritableImage takeScreenshot(final GlassRobot robot) {
final Rectangle2D bounds = Screen.getPrimary().getVisualBounds();
final int width = (int) bounds.getWidth();
final int height = (int) bounds.getHeight();
final int x = (int) bounds.getMinX();
final int y = (int) bounds.getMinY();
return robot.getScreenCapture(null, x, y, width, height, false);
}
Expected result: screenhsot captured
Actual result: java.lang.UnsupportedOperationException
at java.base/java.nio.IntBuffer.array(IntBuffer.java:1049)
at com.sun.glass.ui.monocle.MonocleRobot.getScreenCapture(MonocleRobot.java:209)
at com.sun.glass.ui.GlassRobot.getScreenCapture(GlassRobot.java:200)
REGRESSION : Last worked in version 8
FREQUENCY : always