Skip to content

Commit 284e6ca

Browse files
committed
Configure scrutinizer to fail builds for poor quality
1 parent 1f05f7f commit 284e6ca

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

.scrutinizer.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,17 @@ tools:
99
php_mess_detector: true
1010
php_code_sniffer:
1111
config:
12-
standard: PSR1
12+
standard: PSR2
1313
sensiolabs_security_checker: true
1414
php_loc:
1515
excluded_dirs:
1616
- vendor
1717
- tests
1818
php_pdepend: true
1919
php_sim: true
20+
build_failure_conditions:
21+
- 'elements.rating(<= D).new.exists' # No new classes/methods with a rating of D or worse allowed (useful for legacy code)
22+
- 'issues.label("coding-style").new.exists' # No new coding style issues allowed
23+
- 'issues.label("coding-style").new.count > 5' # More than 5 new coding style issues.
24+
- 'issues.severity(>= MAJOR).new.exists' # New issues of major or higher severity
25+
- 'project.metric("scrutinizer.quality", < 6)' # Code Quality Rating drops below 6

0 commit comments

Comments
 (0)