File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change 22
33. .github/jobs/ci_settings.sh
44
5+ DIR=" $PWD "
6+
57export version=$1
68unittest=$2
79[ " $version " = " 8.1" ] && CODECOVERAGE=1 || CODECOVERAGE=0
@@ -28,18 +30,18 @@ pcov=""
2830phpcov=" "
2931if [ " $CODECOVERAGE " -eq 1 ]; then
3032 phpcov=" -dpcov.enabled=1 -dpcov.directory=webapp/src"
31- pcov=" --coverage-html=${CI_PROJECT_DIR } /coverage-html --coverage-clover coverage.xml"
33+ pcov=" --coverage-html=${DIR } /coverage-html --coverage-clover coverage.xml"
3234fi
3335set +e
34- php $phpcov webapp/bin/phpunit -c webapp/phpunit.xml.dist webapp/tests/$unittest --log-junit ${CI_PROJECT_DIR } /unit-tests.xml --colors=never $pcov > " $GITLABARTIFACTS " /phpunit.out
36+ php $phpcov webapp/bin/phpunit -c webapp/phpunit.xml.dist webapp/tests/$unittest --log-junit ${DIR } /unit-tests.xml --colors=never $pcov > " $GITLABARTIFACTS " /phpunit.out
3537UNITSUCCESS=$?
3638set -e
3739CNT=0
3840THRESHOLD=32
3941if [ $CODECOVERAGE -eq 1 ]; then
4042 CNT=$( sed -n ' /Generating code coverage report/,$p' " $GITLABARTIFACTS " /phpunit.out | grep -v DoctrineTestBundle | grep -cv ^$)
4143 FILE=deprecation.txt
42- sed -n ' /Generating code coverage report/,$p' " $GITLABARTIFACTS " /phpunit.out > ${CI_PROJECT_DIR } /$FILE
44+ sed -n ' /Generating code coverage report/,$p' " $GITLABARTIFACTS " /phpunit.out > ${DIR } /$FILE
4345 if [ $CNT -le $THRESHOLD ]; then
4446 STATE=success
4547 else
You can’t perform that action at this time.
0 commit comments