GitHub Action workflows #2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: PHP Test Project | ||
on: | ||
workflow_dispatch: | ||
pull_request: | ||
paths: | ||
- '**workflows/test-project.yml' | ||
- '**.php' | ||
- '**tests/example/phpunit.xml.dist' | ||
- '**composer.json' | ||
push: | ||
paths: | ||
- '**workflows/test-project.yml' | ||
- '**.php' | ||
- '**tests/example/phpunit.xml.dist' | ||
- '**composer.json' | ||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
jobs: | ||
test-project-php: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 5 | ||
strategy: | ||
matrix: | ||
Check failure on line 28 in .github/workflows/test-project.yml GitHub Actions / PHP Test ProjectInvalid workflow file
|
||
php-version: ["7.4", "8.0", "8.1", "8.2"] | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
- name: Setup PHP | ||
uses: shivammathur/setup-php@v2 | ||
with: | ||
php-version: ${{ matrix.php-version }} | ||
coverage: none | ||
- name: Install dependencies | ||
uses: ramsey/composer-install@v2 | ||
with: | ||
composer-options: '-d tests/example' | ||
- name: Run tests | ||
run: composer tests:example-project |