Checkout Config
build:
nodes:
analysis:
tests:
override:
- php-scrutinizer-run
coverage:
tests:
override:
- command: |
mkdir -p logs
# Install and enable Xdebug for code coverage
if ! php -m | grep -q 'xdebug'; then
pecl install xdebug || true
fi
php -m # Check Xdebug is enabled
php -d xdebug.mode=coverage,develop -d xdebug.start_with_request=yes vendor/bin/phpunit --coverage-clover logs/clover.xml
# - command: |
# mkdir -p build/logs
# # Install and enable Xdebug for code coverage
# if ! php -m | grep -q 'xdebug'; then
# pecl install xdebug || true
# echo "zend_extension=xdebug.so" >> "$(php -r 'echo php_ini_loaded_file();')"
# echo "xdebug.mode=coverage" >> "$(php -r 'echo php_ini_loaded_file();')"
# fi
# php -m # Check Xdebug is enabled
# php -i | grep xdebug.mode # Verify Xdebug mode
# vendor/bin/phpunit --coverage-clover build/logs/clover.xml
coverage:
file: logs/clover.xml
format: clover
idle_timeout: 360
environment:
# Languages
php:
version: "8.2"
Repository Config
filter:
excluded_paths:
- 'tests/*'
checks:
php: true
coding_style:
php:
spaces:
around_operators:
multiplicative: false
concatenation: true