This is an automated email from the ASF dual-hosted git repository. asf-gitbox-commits pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cayenne.git
commit bac03736da8cdec51d920ec4978ea5508daadff2 Author: Andrus Adamchik <[email protected]> AuthorDate: Sun May 10 09:50:09 2026 -0400 JUnit 5 migration of "cayenne-ant" module (phase 2) --- .../java/org/apache/cayenne/tools/DbImporterTaskTest.java | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/cayenne-ant/src/test/java/org/apache/cayenne/tools/DbImporterTaskTest.java b/cayenne-ant/src/test/java/org/apache/cayenne/tools/DbImporterTaskTest.java index 3a2e48566..b0ea2c408 100644 --- a/cayenne-ant/src/test/java/org/apache/cayenne/tools/DbImporterTaskTest.java +++ b/cayenne-ant/src/test/java/org/apache/cayenne/tools/DbImporterTaskTest.java @@ -48,7 +48,6 @@ import static org.apache.cayenne.util.Util.isBlank; import static org.hamcrest.MatcherAssert.assertThat; import static org.junit.jupiter.api.Assertions.assertNotNull; import static org.junit.jupiter.api.Assertions.assertTrue; -import static org.junit.jupiter.api.Assertions.fail; // TODO: we are only testing on Derby. We may need to dynamically switch between DBs // based on "cayenneTestConnection", like we do in cayenne-server, etc. @@ -173,15 +172,10 @@ public class DbImporterTaskTest { } @SuppressWarnings("unchecked") - private void verifyResult(File map, File mapFileCopy) { - try { - FileReader control = new FileReader(map.getAbsolutePath() + "-result"); - FileReader test = new FileReader(mapFileCopy); - assertThat(test, CompareMatcher.isSimilarTo(control).ignoreWhitespace()); - } catch (IOException e) { - e.printStackTrace(); - fail(); - } + private void verifyResult(File map, File mapFileCopy) throws IOException { + FileReader control = new FileReader(map.getAbsolutePath() + "-result"); + FileReader test = new FileReader(mapFileCopy); + assertThat(test, CompareMatcher.isSimilarTo(control).ignoreWhitespace()); } private void prepareDatabase(String sqlFile, DbImportConfiguration dbImportConfiguration) throws Exception {
