Skip to content

Commit 5629de2

Browse files
authored
Merge pull request #46 from iMattPro/fixes
Fix coverage issue
2 parents 706e6a3 + 174b460 commit 5629de2

File tree

1 file changed

+26
-9
lines changed

1 file changed

+26
-9
lines changed

.github/workflows/tests.yml

Lines changed: 26 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -316,11 +316,18 @@ jobs:
316316
DB: ${{steps.database-type.outputs.db}}
317317
COVERAGE: ${{ matrix.COVERAGE == '1' && '1' || '0' }}
318318
run: |
319+
args=()
320+
if [ "$COVERAGE" == "1" ]; then
321+
args+=(--coverage-clover build/logs/clover.xml)
322+
fi
323+
if [ "$FUNCTIONAL_TESTS" == "0" ]; then
324+
args+=(--exclude-group functional)
325+
fi
326+
319327
phpBB/vendor/bin/phpunit \
320328
--configuration "phpBB/ext/$EXTNAME/.github/phpunit-$DB-github.xml" \
321329
--bootstrap ./tests/bootstrap.php \
322-
"$( [[ "$COVERAGE" == "1" ]] && echo "--coverage-clover build/logs/clover.xml" )" \
323-
"$( [[ "$FUNCTIONAL_TESTS" == "0" ]] && echo "--exclude-group functional" )"
330+
"${args[@]}"
324331
working-directory: ./phpBB3
325332

326333
- name: Send code coverage
@@ -465,10 +472,15 @@ jobs:
465472
env:
466473
DB: ${{steps.database-type.outputs.db}}
467474
run: |
468-
phpBB/vendor/bin/phpunit \
469-
--configuration "phpBB/ext/$EXTNAME/.github/phpunit-$DB-github.xml" \
470-
--bootstrap ./tests/bootstrap.php \
471-
"$( [[ "$FUNCTIONAL_TESTS" == "0" ]] && echo "--exclude-group functional" )"
475+
args=()
476+
if [ "$FUNCTIONAL_TESTS" == "0" ]; then
477+
args+=(--exclude-group functional)
478+
fi
479+
480+
phpBB/vendor/bin/phpunit \
481+
--configuration "phpBB/ext/$EXTNAME/.github/phpunit-$DB-github.xml" \
482+
--bootstrap ./tests/bootstrap.php \
483+
"${args[@]}"
472484
working-directory: ./phpBB3
473485
# END PostgreSQL Job
474486

@@ -605,10 +617,15 @@ jobs:
605617
env:
606618
DB: ${{steps.database-type.outputs.db}}
607619
run: |
620+
args=()
621+
if [ "$FUNCTIONAL_TESTS" == "0" ]; then
622+
args+=(--exclude-group functional)
623+
fi
624+
608625
phpBB/vendor/bin/phpunit \
609-
--configuration "phpBB/ext/$EXTNAME/.github/phpunit-$DB-github.xml" \
610-
--bootstrap ./tests/bootstrap.php \
611-
"$( [[ "$FUNCTIONAL_TESTS" == "0" ]] && echo "--exclude-group functional" )"
626+
--configuration "phpBB/ext/$EXTNAME/.github/phpunit-$DB-github.xml" \
627+
--bootstrap ./tests/bootstrap.php \
628+
"${args[@]}"
612629
working-directory: ./phpBB3
613630
# END Other Tests Job
614631

0 commit comments

Comments
 (0)