Skip to content

Commit 5cbc0cf

Browse files
committed
Display the unit test results
1 parent 8c48547 commit 5cbc0cf

File tree

2 files changed

+8
-7
lines changed

2 files changed

+8
-7
lines changed

.github/jobs/unit-tests.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ if [ "$CODECOVERAGE" -eq 1 ]; then
3535
pcov="--coverage-html=${DIR}/coverage-html --coverage-clover coverage.xml"
3636
fi
3737
set +e
38-
php $phpcov webapp/bin/phpunit -c webapp/phpunit.xml.dist webapp/tests/$unittest --log-junit ${DIR}/unit-tests.xml --colors=never $pcov > "$ARTIFACTS"/phpunit.out
38+
php $phpcov webapp/bin/phpunit -c webapp/phpunit.xml.dist webapp/tests/$unittest --log-junit "$ARTIFACTS"/unit-tests.xml --colors=never $pcov > "$ARTIFACTS"/phpunit.out
3939
UNITSUCCESS=$?
4040
set -e
4141
CNT=0

.github/workflows/unit-tests.yml

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -46,14 +46,15 @@ jobs:
4646
run: diff newcodecov .github/jobs/uploadcodecov.sh
4747
- name: Run the unit tests
4848
run: .github/jobs/unit-tests.sh ${{ matrix.PHPVERSION }} ${{ matrix.TEST }}
49-
#- name: Publish Test Results
50-
# uses: EnricoMi/publish-unit-test-result-action@v2
51-
# if: always()
52-
# with:
53-
# files: |
54-
# test-results/**/*.xml
5549
- name: Upload artifact for debugging
5650
uses: actions/upload-artifact@v3
51+
if: ${{ !cancelled() }}
5752
with:
5853
name: unit-test-output
5954
path: /tmp/artifacts
55+
- name: Publish Test Results
56+
uses: EnricoMi/publish-unit-test-result-action@v2
57+
if: ${{ !cancelled() }}
58+
with:
59+
files: |
60+
/tmp/artifacts/unit-tests.xml

0 commit comments

Comments
 (0)