wangzzu commented on code in PR #23244:
URL: https://github.com/apache/flink/pull/23244#discussion_r1300833923


##########
flink-runtime/src/test/java/org/apache/flink/runtime/minicluster/MiniClusterITCase.java:
##########
@@ -127,8 +125,13 @@ public void testHandleStreamingJobsWhenNotEnoughSlot() 
throws Exception {
 
             fail("Job should fail.");
         } catch (JobExecutionException e) {
-            assertThat(e, FlinkMatchers.containsMessage("Job execution 
failed"));
-            assertThat(e, 
FlinkMatchers.containsCause(NoResourceAvailableException.class));
+            assertThat(e)
+                    .satisfies(matching(FlinkMatchers.containsMessage("Job 
execution failed")));
+            assertThat(e)
+                    .satisfies(
+                            matching(
+                                    FlinkMatchers.containsCause(

Review Comment:
   done



##########
flink-runtime/src/test/java/org/apache/flink/runtime/minicluster/MiniClusterITCase.java:
##########
@@ -255,14 +258,14 @@ public void testTwoInputJobFailingEdgeMismatch() throws 
Exception {
 
                 fail("Job should fail.");
             } catch (JobExecutionException e) {
-                assertTrue(findThrowable(e, 
ArrayIndexOutOfBoundsException.class).isPresent());
-                assertTrue(findThrowableWithMessage(e, "2").isPresent());
+                assertThat(findThrowable(e, 
ArrayIndexOutOfBoundsException.class)).isPresent();
+                assertThat(findThrowableWithMessage(e, "2")).isPresent();
             }

Review Comment:
   fixed



-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to