I've tried configuring Scrutinizer to fail whenever the CodeSniffer analysis returns some errors with no luck.
Here's what I tried so far:
V1:
build:
tests:
override:
command: './vendor/bin/phpcs ./src --report=checkstyle --report-file=cs-data'
analysis:
file: 'cs-data'
format: 'php-cs-checkstyle'
V2:
build:
tests:
override:
- 'phpcs-run'
My tools and build_failure_conditions
:
tools:
php_code_sniffer:
config:
standard: "PSR2"
checks:
php:
code_rating: true
duplication: true
build_failure_conditions:
- 'issues.label("coding-style").new.exists'
What's missing?