On Thu, 18 Mar 2021 12:32:50 GMT, Ambarish Rapte <ara...@openjdk.org> wrote:

>> Is there a unit test that can validate this fix?
>
>> Is there a unit test that can validate this fix?
> 
> I have added a unit test using a new shim class. Test verifies size of the 
> map that is added as part of this fix.
> So the test won't compile without this PR.

The new unit test fails on all platforms, as you can see from the GitHub 
actions log:

2021-03-18T12:45:36.7904530Z 
test.javafx.scene.control.ControlAcceleratorSupportTest > 
sanityTestListenerMapShouldBeEmpty FAILED
2021-03-18T12:45:36.8007000Z     java.lang.AssertionError: expected:<0> but 
was:<22>
2021-03-18T12:45:36.8099570Z         at org.junit.Assert.fail(Assert.java:91)
2021-03-18T12:45:36.8201200Z         at 
org.junit.Assert.failNotEquals(Assert.java:645)
2021-03-18T12:45:36.8264450Z         at 
org.junit.Assert.assertEquals(Assert.java:126)
2021-03-18T12:45:36.8366120Z         at 
org.junit.Assert.assertEquals(Assert.java:470)
2021-03-18T12:45:36.8455230Z         at 
org.junit.Assert.assertEquals(Assert.java:454)
2021-03-18T12:45:36.8559230Z         at 
test.javafx.scene.control.ControlAcceleratorSupportTest.sanityTestListenerMapShouldBeEmpty(ControlAcceleratorSupportTest.java:43)
2021-03-18T12:45:36.8886110Z 
2021-03-18T12:45:36.8989430Z 
test.javafx.scene.control.ControlAcceleratorSupportTest > 
testNumberOfListenersByRemovingAndAddingMenuItems FAILED
2021-03-18T12:45:36.9092540Z     java.lang.AssertionError: expected:<4> but 
was:<26>
2021-03-18T12:45:36.9194300Z         at org.junit.Assert.fail(Assert.java:91)
2021-03-18T12:45:36.9296390Z         at 
org.junit.Assert.failNotEquals(Assert.java:645)
2021-03-18T12:45:36.9393550Z         at 
org.junit.Assert.assertEquals(Assert.java:126)
2021-03-18T12:45:36.9495860Z         at 
org.junit.Assert.assertEquals(Assert.java:470)
2021-03-18T12:45:36.9596430Z         at 
org.junit.Assert.assertEquals(Assert.java:454)
2021-03-18T12:45:36.9700420Z         at 
test.javafx.scene.control.ControlAcceleratorSupportTest.testNumberOfListenersByRemovingAndAddingMenuItems(ControlAcceleratorSupportTest.java:65)

-------------

PR: https://git.openjdk.java.net/jfx/pull/429

Reply via email to