Laurent Bourgès wrote:
Kevin,

It is possible to define the Locale (set user.language=...) in the gradle build file, that would avoid touching the java code at all.

I suppose this could be done, and if there are many such failing tests, it might be an OK short-term solution. It's probably not the best long-term solution, since I think it is better for any test that is sensitive to the Locale to set it in the test itself.

Sven: if you run using the --continue option (so it won't stop after the first batch of failing tests), are there any more tests that fail in other modules?

-- Kevin




I have no opinion what is preferable to have less maintenance work or problems in future.

Laurent

2018-03-12 16:09 GMT+01:00 Kevin Rushforth <[email protected] <mailto:[email protected]>>:

    I haven't run these with a Locale other than en_US, but given the
    nature of the failure, it looks like you may have discovered
    another Locale-related test bug.

    We had another test that was fixed by setting the default Locale
    to Locale.US in a static @BeforeClass method in the test class
    [1]. Perhaps a similar solution is needed here.

    -- Kevin

    [1] https://bugs.openjdk.java.net/browse/JDK-8160039
    <https://bugs.openjdk.java.net/browse/JDK-8160039>



    Sven Reimers wrote:

        Hi,

        getting back into the OpenJFX I started with a fresh clone and
        ran gradle
        test..

        I got

        test.javafx.scene.control.SpinnerTest >
        dblSpinner_testToString_valueInRange FAILED
            junit.framework.ComparisonFailure: null expected:<0[.]3>
        but was:<0[,]3>
                at junit.framework.Assert.assertEquals(Assert.java:81)
                at junit.framework.Assert.assertEquals(Assert.java:87)
                at
        
test.javafx.scene.control.SpinnerTest.dblSpinner_testToString_valueInRange(SpinnerTest.java:607)

        test.javafx.scene.control.SpinnerTest >
        dblSpinner_testFromString_valueInRange FAILED
            junit.framework.AssertionFailedError: expected:<0.3> but
        was:<0.0>
                at junit.framework.Assert.fail(Assert.java:47)
                at junit.framework.Assert.failNotEquals(Assert.java:283)
                at junit.framework.Assert.assertEquals(Assert.java:64)
                at junit.framework.Assert.assertEquals(Assert.java:71)
                at
        
test.javafx.scene.control.SpinnerTest.dblSpinner_testFromString_valueInRange(SpinnerTest.java:615)

        test.javafx.scene.control.SpinnerTest >
        test_jdk_8150946_testCancel FAILED
            junit.framework.ComparisonFailure: null expected:<2[.]5>
        but was:<2[,]5>
                at junit.framework.Assert.assertEquals(Assert.java:81)
                at junit.framework.Assert.assertEquals(Assert.java:87)
                at
        
test.javafx.scene.control.SpinnerTest.test_jdk_8150946_testCancel(SpinnerTest.java:1334)

        test.javafx.scene.control.SpinnerTest >
        test_jdk_8150946_testCommit_valid
        FAILED
            junit.framework.AssertionFailedError: expected:<2.5> but
        was:<2.0>
                at junit.framework.Assert.fail(Assert.java:47)
                at junit.framework.Assert.failNotEquals(Assert.java:283)
                at junit.framework.Assert.assertEquals(Assert.java:64)
                at junit.framework.Assert.assertEquals(Assert.java:71)
                at
        
test.javafx.scene.control.SpinnerTest.test_jdk_8150946_testCommit_valid(SpinnerTest.java:1308)

        This is with gradle 46, 9.0.4 on a german locale OS X...

        Any ideas what to look for?

        Thanks

        Sven



--
--
Laurent Bourgès

Reply via email to