Skip to content

Commit 39c9e17

Browse files
committed
Make the script fail if there are compilation errors in tests
Signed-off-by: Flavia Rainone <frainone@redhat.com>
1 parent 835356a commit 39c9e17

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

.github/workflows/ci.yml

+5-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,11 @@ jobs:
3434
- name: Print Version
3535
run: mvn -v
3636
- name: Build
37-
run: mvn -U -B -fae -DskipTests -Dfindbugs clean install
37+
run: |
38+
mvn -U -B -fae -DskipTests -Dfindbugs clean install | tee outfile.txt
39+
echo "Checking for build errors"
40+
grep \\[ERROR\\] outfile.txt && echo "Found errors, see above" || echo "No errors found"
41+
! $(grep -q \\[ERROR\\] outfile.txt )
3842
- name: Tar Maven Repo
3943
shell: bash
4044
run: tar -czf maven-repo.tgz -C ~ .m2/repository

0 commit comments

Comments
 (0)