Uploaded image for project: 'Flink'
  1. Flink
  2. FLINK-3353

CSV-related tests may fail depending on locale

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 1.0.0
    • 1.0.0
    • Tests
    • None

    Description

      As I've been running some tests, three suites (KMeansWithBroadcastSetITCase.java, ScalaCsvReaderWithPOJOITCase.scala and CsvReaderITCase.java) kept failing locally because the expected results (string literals) were matched against an object rendered as a string using the String.format method, a method whose result depends on the default Locale; as my Locale (Italian) renders doubles with a comma instead of a dot as the decimal separator, the representation of doubles diverged from the expected one, thus making my tests fail, despite the results actually being correct.

      As the result is hard-coded, it makes sense to explicitly use the US locale to represent those object. I'll open a PR with my solution ASAP.

      Attachments

        Activity

          People

            stefanobaghino Stefano Baghino
            stefanobaghino Stefano Baghino
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: