Add coding standard check
Signed-off-by: Maurício Meneghini Fauth <mauricio@fauth.dev>
This commit is contained in:
parent
19ef2d84d4
commit
8577e70888
30
.github/workflows/continuous-integration.yml
vendored
30
.github/workflows/continuous-integration.yml
vendored
@ -46,3 +46,33 @@ jobs:
|
||||
|
||||
- name: "Run tests"
|
||||
run: "vendor/bin/phpunit --no-coverage --disallow-test-output --exclude-group selenium"
|
||||
|
||||
coding-standards:
|
||||
name: "Check coding standards"
|
||||
runs-on: "ubuntu-latest"
|
||||
|
||||
strategy:
|
||||
matrix:
|
||||
php-version:
|
||||
- "7.1"
|
||||
|
||||
steps:
|
||||
- name: "Checkout"
|
||||
uses: "actions/checkout@v2"
|
||||
|
||||
- name: "Install PHP"
|
||||
uses: "shivammathur/setup-php@v2"
|
||||
with:
|
||||
coverage: "none"
|
||||
php-version: "${{ matrix.php-version }}"
|
||||
ini-values: "memory_limit=-1"
|
||||
|
||||
- name: "Install dependencies"
|
||||
uses: "ramsey/composer-install@v2"
|
||||
with:
|
||||
dependency-versions: "highest"
|
||||
|
||||
- name: "Check coding standards"
|
||||
run: |
|
||||
vendor/bin/phpcs --config-set installed_paths ../../phpmyadmin/coding-standard
|
||||
vendor/bin/phpcs
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
<?xml version="1.0"?>
|
||||
<ruleset name="phpMyAdmin Coding Standard">
|
||||
<rule ref="./vendor/phpmyadmin/coding-standard/PMAStandard/ruleset.xml">
|
||||
<rule ref="PMAStandard">
|
||||
<exclude name="Generic.Metrics.NestingLevel.TooHigh"/>
|
||||
<exclude name="PSR1.Files.SideEffects.FoundWithSymbols"/>
|
||||
<exclude name="PSR1.Classes.ClassDeclaration.MissingNamespace"/>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user