filter: excluded_paths: - 'tests/*' dependency_paths: - 'vendor/' checks: php: true build: dependencies: before: - restore-from-cache repository "dependencies" - restore-from-cache repository "phpunit" override: - composer install --no-interaction --optimize-autoloader - command: wget https://get.symfony.com/cli/installer -O - | bash only_if: '[ "$SCRUTINIZER_BRANCH" == "master" ] && [ -z "$SCRUTINIZER_PR_SOURCE_BRANCH" ]' after: - store-in-cache repository "dependencies" vendor/ nodes: tests: tests: override: - composer validate - ./vendor/bin/php-cs-fixer fix --dry-run -v - command: '~/.symfony/bin/symfony security:check --force-update' only_if: '[ "$SCRUTINIZER_BRANCH" == "master" ] && [ -z "$SCRUTINIZER_PR_SOURCE_BRANCH" ]' - command: './vendor/bin/phpunit --coverage-clover=coverage-clover.xml' coverage: file: 'coverage-clover.xml' format: 'clover' - php-scrutinizer-run environment: php: version: '7.2' build_failure_conditions: - 'elements.rating(<= D).new.exists' # No new classes/methods with a rating of D or worse. - 'project.metric("scrutinizer.quality", < 8)' # Code Quality Rating drops below 8. - 'project.metric("scrutinizer.test_coverage", < 0.80)' # Code Coverage drops below 80%.
build: nodes: analysis: project_setup: override: - 'true' tests: override: - php-scrutinizer-run - command: phpcs-run use_website_config: true checks: php: fix_php_opening_tag: false remove_php_closing_tag: false one_class_per_file: false side_effects_or_types: false no_mixed_inline_html: false require_braces_around_control_structures: false php5_style_constructor: false no_global_keyword: false avoid_usage_of_logical_operators: false psr2_class_declaration: false no_underscore_prefix_in_properties: false no_underscore_prefix_in_methods: false blank_line_after_namespace_declaration: false single_namespace_per_use: false psr2_switch_declaration: false psr2_control_structure_declaration: false avoid_superglobals: false security_vulnerabilities: false no_exit: false coding_style: php: { } filter: { }