Github user fhueske commented on a diff in the pull request:
https://github.com/apache/flink/pull/1098#discussion_r39253553
--- Diff:
flink-staging/flink-streaming/flink-streaming-scala/src/test/java/org/apache/flink/streaming/scala/api/CsvOutputFormatITCase.java
---
@@ -36,6 +37,10 @@ protected void preSubmit() throws Exception {
@Override
protected void testProgram() throws Exception {
OutputFormatTestPrograms.wordCountToCsv(WordCountData.TEXT,
resultPath);
+ OutputFormatTestPrograms.wordCountToCsv(WordCountData.TEXT,
resultPath, 1);
--- End diff --
It is expected that the test fails if you set the overwrite mode to
`NO_OVERWRITE` because you start multiple programs that all write to the same
location.
I debugged the issue and found that the `ForkableFlinkMiniCluster` sets the
overwrite mode to OVERWRITE. That explains the behavior. However, this also
means that you cannot test the correctness of your methods by setting the
overwrite mode to OVERWRITE because this is the default behavior.
I would change the `CsvOuputFormatITCase` to extend
`StreamingMultipleProgramsTestBase` and run each program in a dedicated test
method.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---