Skip to content

CI

CI #44

Workflow file for this run

name: CI
on:
schedule: [ { cron: '30 5 * * 1,5' } ]
pull_request:
push:
branches: [ "[0-9]+.[0-9]+" ]
paths-ignore: [ "README.md", "CHANGELOG.md", "doc/**/*" ]
jobs:
analysis:
name: Analysis
permissions:
actions: read
contents: read
checks: write
runs-on: [ ubuntu-latest ]
steps:
- uses: actions/checkout@v3
- uses: shivammathur/setup-php@v2
with:
php-version: "8.1"
- uses: ramsey/composer-install@v2
- run: mkdir -p report/psalm report/phpcs
if: success() || failure()
- run: composer exec -- psalm --long-progress --output-format=github --report=report/psalm/checkstyle.xml --report-show-info=false
if: success() || failure()
- run: composer exec -- phpcs --colors --report=checkstyle --report-checkstyle=report/phpcs/checkstyle.xml
if: success() || failure()
- uses: jwgmeligmeyling/checkstyle-github-action@master
if: success() || failure()
with:
name: Psalm
path: report/psalm/checkstyle.xml
- uses: jwgmeligmeyling/checkstyle-github-action@master
if: success() || failure()
with:
name: PHP_CodeSniffer
path: report/phpcs/checkstyle.xml
test:
name: Tests
needs: analysis
runs-on: [ubuntu-latest]
continue-on-error: ${{ matrix.dependency-versions == 'lowest' }}
strategy:
matrix:
php: [ "8.1", "8.2", "8.3" ]
dependency-versions: [ lowest, highest ]
steps:
- uses: actions/checkout@v3
- uses: shivammathur/setup-php@v2
with:
php-version: "${{ matrix.php }}"
- uses: ramsey/composer-install@v2
with:
dependency-versions: "${{ matrix.dependency-versions }}"
composer-options: "${{ matrix.composer-options }}"
- run: mkdir -p report/phpunit
if: success() || failure()
- run: composer exec -- phpunit --testsuite tests --colors=always
if: success() || failure()