File tree Expand file tree Collapse file tree 4 files changed +10
-12
lines changed Expand file tree Collapse file tree 4 files changed +10
-12
lines changed Original file line number Diff line number Diff line change @@ -247,10 +247,6 @@ apk add curl bash vim nodejs npm mariadb mariadb-client openrc
247
247
curl ' https://dl.bintray.com/php-alpine/key/php-alpine.rsa.pub' -o /etc/apk/keys/php-alpine.rsa.pub
248
248
apk add php7-curl php7-dom php7-fpm php7-json php7-session php7-openssl php7-pdo_mysql php7-pdo php7-fileinfo --repository https://dl.bintray.com/php-alpine/v3.10/php-7.4
249
249
250
- # Install and enable Xdebug for code coverage with coveralls
251
- pecl install xdebug
252
- docker-php-ext-enable xdebug
253
-
254
250
# Config ~/.vimrc file
255
251
cat << EOF -> ~/.vimrc
256
252
set sts=2
@@ -969,6 +965,10 @@ rc-service nginx start
969
965
rc-update add php-fpm7 default
970
966
rc-update add nginx default
971
967
968
+ # Install and enable Xdebug for code coverage with coveralls
969
+ pecl install xdebug
970
+ docker-php-ext-enable xdebug
971
+
972
972
# Don't stop the container on server crash
973
973
set +x
974
974
sleep 3
Original file line number Diff line number Diff line change @@ -65,6 +65,7 @@ $dockerdir/remove-container.sh
65
65
# Install container
66
66
sudo docker run \
67
67
-d \
68
+ -e UPLOAD_COVERALLS=false \
68
69
-e LARAVEL_HTTP_PORT=$LARAVEL_HTTP_PORT \
69
70
-e LARAVEL_SERVER_ENV=$LARAVEL_SERVER_ENV \
70
71
-e LARAVEL_MAXMIND_COUNTRY_LICENSE_KEY=$LARAVEL_MAXMIND_COUNTRY_LICENSE_KEY \
Original file line number Diff line number Diff line change 59
59
</php >
60
60
<logging >
61
61
<log type =" coverage-clover" target =" build/logs/clover.xml" />
62
+ <log type =" coverage-html" target =" build/logs/html" />
62
63
</logging >
63
64
</phpunit >
Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ CREATE_DB=true
11
11
CLEAR_CONFIG_CACHE=true
12
12
13
13
# UPLOAD_COVERALLS=<true|false>
14
- UPLOAD_COVERALLS=true
14
+ UPLOAD_COVERALLS=${UPLOAD_COVERALLS- true}
15
15
16
16
if [ ! -e vendor/bin/phpunit ]
17
17
then
68
68
# Clean up
69
69
rm -rf $localdirname /build/
70
70
71
+ # Run unit and feature tests
72
+ vendor/bin/phpunit -v
73
+
71
74
if [ " $UPLOAD_COVERALLS " == " true" ]
72
75
then
73
- # Run unit and feature tests and output coverage data
74
- vendor/bin/phpunit --coverage-clover " $localdirname /build/logs/clover.xml"
75
-
76
76
# Run the code coverage analysis
77
77
vendor/bin/php-coveralls -v
78
78
79
- else
80
- # Run unit and feature tests and output html data
81
- vendor/bin/phpunit --coverage-html " $localdirname /build/logs/html"
82
-
83
79
fi
84
80
85
81
# Store the error code from the previous command because
You can’t perform that action at this time.
0 commit comments