aboutsummaryrefslogtreecommitdiff
path: root/examples/src/main/python/mllib/multi_label_metrics_example.py
diff options
context:
space:
mode:
authorhyukjinkwon <gurwls223@gmail.com>2017-01-02 15:17:02 +0000
committerSean Owen <sowen@cloudera.com>2017-01-02 15:17:02 +0000
commitf1330b1d9e7b1d5de611e59eecae1bf0b0616d81 (patch)
treee7d1333a51b6a55fb72fb37afb4b6dea4c44166b /examples/src/main/python/mllib/multi_label_metrics_example.py
parent0ac2f1e71f62ec925ed0e19c4654759d155efc35 (diff)
downloadspark-f1330b1d9e7b1d5de611e59eecae1bf0b0616d81.tar.gz
spark-f1330b1d9e7b1d5de611e59eecae1bf0b0616d81.tar.bz2
spark-f1330b1d9e7b1d5de611e59eecae1bf0b0616d81.zip
[SPARK-19022][TESTS] Fix tests dependent on OS due to different newline characters
## What changes were proposed in this pull request? There are two tests failing on Windows due to the different newlines. ``` - StreamingQueryProgress - prettyJson *** FAILED *** (0 milliseconds) "{ "id" : "39788670-6722-48b7-a248-df6ba08722ac", "runId" : "422282f1-3b81-4b47-a15d-82dda7e69390", "name" : "myName", ... }" did not equal "{ "id" : "39788670-6722-48b7-a248-df6ba08722ac", "runId" : "422282f1-3b81-4b47-a15d-82dda7e69390", "name" : "myName", ... }" ... ``` ``` - StreamingQueryStatus - prettyJson *** FAILED *** (0 milliseconds) "{ "message" : "active", "isDataAvailable" : true, "isTriggerActive" : false }" did not equal "{ "message" : "active", "isDataAvailable" : true, "isTriggerActive" : false }" ... ``` The reason is, `pretty` in `org.json4s.pretty` writes OS-dependent newlines but the string defined in the tests are `\n`. This ends up with test failures. This PR proposes to compare these regardless of newline concerns. ## How was this patch tested? Manually tested via AppVeyor. **Before** https://ci.appveyor.com/project/spark-test/spark/build/417-newlines-fix-before **After** https://ci.appveyor.com/project/spark-test/spark/build/418-newlines-fix Author: hyukjinkwon <gurwls223@gmail.com> Closes #16433 from HyukjinKwon/tests-StreamingQueryStatusAndProgressSuite.
Diffstat (limited to 'examples/src/main/python/mllib/multi_label_metrics_example.py')
0 files changed, 0 insertions, 0 deletions