From 27588f5045e3c2f3f41ab9a295daf357a35201e1 Mon Sep 17 00:00:00 2001 From: Christian Stein Date: Wed, 27 Nov 2024 11:15:38 +0100 Subject: [PATCH] Add JUnit 5.11.0 integration test --- src/it/jupiter-5.11.0-platform-1.11.0/pom.xml | 37 +++++++++++++++++++ .../src/test/java/Tests.java | 7 ++++ .../jupiter-5.11.0-platform-1.11.0/verify.bsh | 31 ++++++++++++++++ 3 files changed, 75 insertions(+) create mode 100644 src/it/jupiter-5.11.0-platform-1.11.0/pom.xml create mode 100644 src/it/jupiter-5.11.0-platform-1.11.0/src/test/java/Tests.java create mode 100644 src/it/jupiter-5.11.0-platform-1.11.0/verify.bsh diff --git a/src/it/jupiter-5.11.0-platform-1.11.0/pom.xml b/src/it/jupiter-5.11.0-platform-1.11.0/pom.xml new file mode 100644 index 0000000..b1c0784 --- /dev/null +++ b/src/it/jupiter-5.11.0-platform-1.11.0/pom.xml @@ -0,0 +1,37 @@ + + + 4.0.0 + + + it + setup + 0 + + + jupiter-5.11.0-platform-1.11.0 + + + + org.junit.jupiter + junit-jupiter-api + 5.11.0 + test + + + + + + + @project.groupId@ + @project.artifactId@ + + + + 5.11.0 + + + + + + diff --git a/src/it/jupiter-5.11.0-platform-1.11.0/src/test/java/Tests.java b/src/it/jupiter-5.11.0-platform-1.11.0/src/test/java/Tests.java new file mode 100644 index 0000000..e9d9bf5 --- /dev/null +++ b/src/it/jupiter-5.11.0-platform-1.11.0/src/test/java/Tests.java @@ -0,0 +1,7 @@ +import org.junit.jupiter.api.Test; + +class Tests { + + @Test + void test() {} +} diff --git a/src/it/jupiter-5.11.0-platform-1.11.0/verify.bsh b/src/it/jupiter-5.11.0-platform-1.11.0/verify.bsh new file mode 100644 index 0000000..ed28e1a --- /dev/null +++ b/src/it/jupiter-5.11.0-platform-1.11.0/verify.bsh @@ -0,0 +1,31 @@ +import it.Verifier; +import it.Verifier; + +Verifier verifier = new Verifier(basedir.toPath()); + +verifier.verifyBadLines(); + +verifier.verifyReadable(new String[] { + "pom.xml", + "src/test/java/Tests.java", + "target/test-classes/Tests.class" +}); + +verifier.verifyNotExists(new String[] { + "target/classes", + "target/surefire-reports" +}); + +verifier.verifyLogMatches(new String[] { + ">> BEGIN >>", + "[INFO] Launching JUnit Platform 1.11.0...", + ">> Plugin setup... >>", + "[DEBUG] junit.platform.version = 1.11.0", + "[DEBUG] junit.jupiter.version = 5.11.0", + "[DEBUG] junit.vintage.version = 5.11.0", + ">> Platform executes tests...>>", + "[INFO] BUILD SUCCESS", + ">> END. >>" +}); + +return verifier.isOk();