Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8265828

[TestBug] Save and restore the default Locale in javafx.base unit test LocalDateTimeStringConverterTest

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: P4
    • Resolution: Unresolved
    • Affects Version/s: openjfx17
    • Fix Version/s: tbd
    • Component/s: javafx
    • Subcomponent:
    • CPU:
      generic
    • OS:
      generic

      Description

      javafx.base unit test LocalDateTimeStringConverterTest changes default locale to US.
      While it is needed for this test, setting default locale changes the global state of VM default. A cleaner approach would be -
      1) Save the current default locale before this test is run
      2) Set the default locale to US as this test needs it
      3) Restore the default locale to the one saved in step 1 after all the test cases in LocalDateTimeStringConverterTest are executed.

      A similar fix was done in controls test - please see JDK-8264952.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              aghaisas Ajit Ghaisas
              Reporter:
              aghaisas Ajit Ghaisas
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated: