Skip to content

Commit fb7a7bc

Browse files
committed
build: run ITs by default in mvn-test-no-boilerplate.sh (verify) and log start; tests: add INFO logs per dynamic OpenRPC example (#29)
1 parent f3b59b0 commit fb7a7bc

File tree

3 files changed

+11
-6
lines changed

3 files changed

+11
-6
lines changed

json-java21-schema/mvn-test-no-boilerplate.sh

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,9 @@ else
2020
MVN_CMD="mvn"
2121
fi
2222

23-
timeout 120 $MVN_CMD test "$@" 2>&1 | awk '
23+
echo "[INFO] Running: $MVN_CMD verify $@"
24+
25+
timeout 120 $MVN_CMD verify "$@" 2>&1 | awk '
2426
BEGIN {
2527
scanning_started = 0
2628
compilation_section = 0
@@ -60,12 +62,12 @@ test_section {
6062
6163
# Before test section starts, show important lines only
6264
!test_section && scanning_started {
63-
if (/INFO.*Scanning|INFO.*Building|INFO.*resources|INFO.*compiler|INFO.*surefire|ERROR|FAILURE/) {
65+
if (/INFO.*Scanning|INFO.*Building|INFO.*resources|INFO.*compiler|INFO.*surefire|INFO.*failsafe|ERROR|FAILURE/) {
6466
print
6567
}
6668
# Show compilation warnings/errors
6769
if (/WARNING.*COMPILATION|ERROR.*/) {
6870
print
6971
}
7072
}
71-
'
73+
'

json-java21-schema/src/test/java/io/github/simbo1905/json/schema/OpenRPCSchemaValidationIT.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ Stream<DynamicTest> validateOpenRPCExamples() throws Exception {
5555
assertThat(jsons).isNotEmpty();
5656

5757
return jsons.stream().map(path -> DynamicTest.dynamicTest(path.getFileName().toString(), () -> {
58+
LOG.info(() -> "TEST: " + getClass().getSimpleName() + "#" + path.getFileName());
5859
String doc = Files.readString(path, StandardCharsets.UTF_8);
5960
boolean expectedValid = !path.getFileName().toString().contains("-bad-");
6061
boolean actualValid = schema.validate(Json.parse(doc)).valid();

mvn-test-no-boilerplate.sh

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,9 @@ else
2020
MVN_CMD="mvn"
2121
fi
2222

23-
timeout 120 $MVN_CMD test "$@" 2>&1 | awk '
23+
echo "[INFO] Running: $MVN_CMD verify $@"
24+
25+
timeout 120 $MVN_CMD verify "$@" 2>&1 | awk '
2426
BEGIN {
2527
scanning_started = 0
2628
compilation_section = 0
@@ -60,12 +62,12 @@ test_section {
6062
6163
# Before test section starts, show important lines only
6264
!test_section && scanning_started {
63-
if (/INFO.*Scanning|INFO.*Building|INFO.*resources|INFO.*compiler|INFO.*surefire|ERROR|FAILURE/) {
65+
if (/INFO.*Scanning|INFO.*Building|INFO.*resources|INFO.*compiler|INFO.*surefire|INFO.*failsafe|ERROR|FAILURE/) {
6466
print
6567
}
6668
# Show compilation warnings/errors
6769
if (/WARNING.*COMPILATION|ERROR.*/) {
6870
print
6971
}
7072
}
71-
'
73+
'

0 commit comments

Comments
 (0)