Skip to content

Commit

Permalink
add workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
overtrue committed Mar 4, 2022
1 parent f9ec8ae commit bdbc87a
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 0 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Lint
on: [push, pull_request]

jobs:
phpstan:
name: PHPStan
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: Install Dependencies
run: composer install --no-progress
- name: Run PHPStan
run: ./vendor/bin/phpstan analyse --no-progress

php_cs_fixer:
name: PHP-CS-Fxier
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: Install Dependencies
run: composer install --no-progress
- name: Run PHP-CS-Fxier
run: composer check-style
22 changes: 22 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Test
on: [push, pull_request]

jobs:
phpunit:
name: PHP-${{ matrix.php_version }}-${{ matrix.perfer }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
php_version:
- 8.0
- 8.1
perfer:
- stable
- lowest
steps:
- uses: actions/checkout@master
- name: Install Dependencies
run: composer update --prefer-dist --no-interaction --no-suggest --prefer-${{ matrix.perfer }}
- name: Run PHPUnit
run: ./vendor/bin/phpunit

0 comments on commit bdbc87a

Please sign in to comment.