Tests: Assert-Beschreibungen korrigiert/ergänzt
[demos/kafka/training] / src / test / java / de / juplo / kafka / ApplicationTests.java
index 6f58180..f541093 100644 (file)
@@ -129,7 +129,9 @@ class ApplicationTests
                {
                        Long expected = offsetsToCheck.get(tp) + 1;
                        log.debug("Checking, if the offset for {} is {}", tp, expected);
-                       assertThat(offset).isEqualTo(expected);
+                       assertThat(offset)
+                                       .describedAs("Committed offset corresponds to the offset of the consumer")
+                                       .isEqualTo(expected);
                });
        }
 
@@ -147,7 +149,9 @@ class ApplicationTests
                                withProgress.add(tp);
                        }
                });
-               assertThat(withProgress).isNotEmpty().describedAs("Found no partitions with any offset-progress");
+               assertThat(withProgress)
+                               .describedAs("Some offsets must have changed, compared to the old offset-positions")
+                               .isNotEmpty();
        }