Skip to content

Commit

Permalink
Merge branch 'master' of github.com:PhpGt/DomValidation
Browse files Browse the repository at this point in the history
  • Loading branch information
g105b committed Mar 28, 2023
2 parents 3bc7f99 + c5751b4 commit e6c3d4f
Show file tree
Hide file tree
Showing 26 changed files with 1,898 additions and 349 deletions.
65 changes: 61 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ on: [push]
jobs:
composer:
runs-on: ubuntu-latest
strategy:
matrix:
php: [ 8.1, 8.2 ]

steps:
- uses: actions/checkout@v3
Expand All @@ -18,7 +21,7 @@ jobs:
- name: Composer install
uses: php-actions/composer@v6
with:
php_version: 8.1
php_version: ${{ matrix.php }}

- name: Archive build
run: mkdir /tmp/github-actions/ && tar -cvf /tmp/github-actions/build.tar ./
Expand All @@ -31,7 +34,10 @@ jobs:

phpunit:
runs-on: ubuntu-latest
needs: [composer]
needs: [ composer ]
strategy:
matrix:
php: [ 8.1, 8.2 ]

outputs:
coverage: ${{ steps.store-coverage.outputs.coverage_text }}
Expand All @@ -50,7 +56,7 @@ jobs:
env:
XDEBUG_MODE: cover
with:
php_version: 8.1
php_version: ${{ matrix.php }}
php_extensions: xdebug
configuration: test/phpunit/phpunit.xml
bootstrap: vendor/autoload.php
Expand Down Expand Up @@ -83,7 +89,10 @@ jobs:

phpstan:
runs-on: ubuntu-latest
needs: [composer]
needs: [ composer ]
strategy:
matrix:
php: [ 8.1, 8.2 ]

steps:
- uses: actions/download-artifact@v3
Expand All @@ -97,8 +106,56 @@ jobs:
- name: PHP Static Analysis
uses: php-actions/phpstan@v3
with:
php_version: ${{ matrix.php }}
path: src/

phpmd:
runs-on: ubuntu-latest
needs: [ composer ]
strategy:
matrix:
php: [ 8.1, 8.2 ]

steps:
- uses: actions/download-artifact@v3
with:
name: build-artifact
path: /tmp/github-actions

- name: Extract build archive
run: tar -xvf /tmp/github-actions/build.tar ./

- name: PHP Mess Detector
uses: php-actions/phpmd@v1
with:
php_version: ${{ matrix.php }}
path: src/
output: text
ruleset: phpmd.xml

phpcs:
runs-on: ubuntu-latest
needs: [ composer ]
strategy:
matrix:
php: [ 8.1, 8.2 ]

steps:
- uses: actions/download-artifact@v3
with:
name: build-artifact
path: /tmp/github-actions

- name: Extract build archive
run: tar -xvf /tmp/github-actions/build.tar ./

- name: PHP Code Sniffer
uses: php-actions/phpcs@v1
with:
php_version: ${{ matrix.php }}
path: src/
standard: phpcs.xml

remove_old_artifacts:
runs-on: ubuntu-latest

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ This repository performs W3C form validation for projects that have a [server-si
<a href="https://github.com/PhpGt/DomValidation/actions" target="_blank">
<img src="https://badge.status.php.gt/domvalidation-build.svg" alt="Build status" />
</a>
<a href="https://scrutinizer-ci.com/g/PhpGt/DomValidation" target="_blank">
<a href="https://app.codacy.com/gh/PhpGt/DomValidation" target="_blank">
<img src="https://badge.status.php.gt/domvalidation-quality.svg" alt="Code quality" />
</a>
<a href="https://app.codecov.io/gh/PhpGt/DomValidation" target="_blank">
Expand Down
6 changes: 4 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,10 @@
},

"require-dev": {
"phpunit/phpunit": "^10",
"phpstan/phpstan": "^1.7.2"
"phpunit/phpunit": "^10.0",
"phpstan/phpstan": "^1.10",
"phpmd/phpmd": "^2.13",
"squizlabs/php_codesniffer": "^3.7"
},

"autoload": {
Expand Down
Loading

0 comments on commit e6c3d4f

Please sign in to comment.