GJL commented on a change in pull request #10071: [FLINK-14371][runtime, tests] 
Enable 
ClassLoaderITCase/WindowCheckpointingITCase/EventTimeWindowCheckpointingITCase 
for NG scheduling
URL: https://github.com/apache/flink/pull/10071#discussion_r342136560
 
 

 ##########
 File path: 
flink-tests/src/test/java/org/apache/flink/test/classloading/ClassLoaderITCase.java
 ##########
 @@ -282,10 +278,12 @@ public void 
testCheckpointingCustomKvStateJobWithCustomClassLoader() throws IOEx
                        Collections.singleton(new 
Path(CHECKPOINTING_CUSTOM_KV_STATE_JAR_PATH)),
                        Collections.emptyList());
 
-               expectedException.expectCause(
-                       Matchers.hasProperty("cause", 
isA(SuccessException.class)));
-
-               program.invokeInteractiveModeForExecution();
+               try {
+                       program.invokeInteractiveModeForExecution();
+                       fail("exception should happen");
+               } catch (Exception e) {
 
 Review comment:
   It's enough to catch `ProgramInvocationException` here. All other exceptions 
will fail the test anyways.
   
   Strictly speaking, we relax the assertion a bit. `SuccessException` is now 
allowed to appear anywhere in the causal chain, whereas the test before was 
asserting:
   
   ```
   assertThat(e.getCause().getCause(), instanceOf(SuccessException.class));
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to