Details
Description
The test java/awt/Multiscreen/MultiScreenLocationTest/MultiScreenLocationTest.java fails on *macOS* system with dual monitor with the following diagnostic:
```
#section:main
----------messages:(5/208)----------
command: main MultiScreenLocationTest
reason: User specified action: run main MultiScreenLocationTest
Mode: othervm
Additional options from @modules: --add-modules java.desktop
elapsed time (seconds): 0.317
----------configuration:(3/40)----------
Boot Layer
add modules: java.desktop
----------System.out:(0/0)----------
----------System.err:(11/699)----------
java.lang.RuntimeException: Robot.mouseMove test failed on Screen #0!
at MultiScreenLocationTest.main(MultiScreenLocationTest.java:80)
at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
at java.base/java.lang.reflect.Method.invoke(Method.java:578)
at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
at java.base/java.lang.Thread.run(Thread.java:1589)
JavaTest Message: Test threw exception: java.lang.RuntimeException: Robot.mouseMove test failed on Screen #0!
JavaTest Message: shutting down test
```
The issue was observed with 20-ea+10-585, 19+35-2237, 18.0.2+9-61, 17.0.2+8-86 on macOS-12, macOS-11 both x86_64 and aarch64
*Reproducibility*: ~100%
*Steps to reproduce*:
```
$ ../../jtreg/bin/jtreg -testjdk:../../jdk/openjdk/jdk-20.jdk/Contents/Home/ test/jdk/java/awt/Multiscreen/MultiScreenLocationTest/MultiScreenLocationTest.java
```
```
#section:main
----------messages:(5/208)----------
command: main MultiScreenLocationTest
reason: User specified action: run main MultiScreenLocationTest
Mode: othervm
Additional options from @modules: --add-modules java.desktop
elapsed time (seconds): 0.317
----------configuration:(3/40)----------
Boot Layer
add modules: java.desktop
----------System.out:(0/0)----------
----------System.err:(11/699)----------
java.lang.RuntimeException: Robot.mouseMove test failed on Screen #0!
at MultiScreenLocationTest.main(MultiScreenLocationTest.java:80)
at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
at java.base/java.lang.reflect.Method.invoke(Method.java:578)
at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
at java.base/java.lang.Thread.run(Thread.java:1589)
JavaTest Message: Test threw exception: java.lang.RuntimeException: Robot.mouseMove test failed on Screen #0!
JavaTest Message: shutting down test
```
The issue was observed with 20-ea+10-585, 19+35-2237, 18.0.2+9-61, 17.0.2+8-86 on macOS-12, macOS-11 both x86_64 and aarch64
*Reproducibility*: ~100%
*Steps to reproduce*:
```
$ ../../jtreg/bin/jtreg -testjdk:../../jdk/openjdk/jdk-20.jdk/Contents/Home/ test/jdk/java/awt/Multiscreen/MultiScreenLocationTest/MultiScreenLocationTest.java
```