-
Notifications
You must be signed in to change notification settings - Fork 21
38 lines (33 loc) · 1.05 KB
/
code_checks.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
# .github/workflows/code_checks.yaml
name: code check
on:
pull_request: null
push:
branches:
- master
jobs:
tests:
runs-on: ubuntu-latest
strategy:
matrix:
php: ['8.1', '8.2', '8.3']
name: PHP ${{ matrix.php }} tests
env:
PHP_CS_FIXER_IGNORE_ENV: 1
steps:
- uses: actions/checkout@v2
- uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: intl, iconv, openssl
coverage: none
- name: Download dependencies
run: composer update --no-ansi --prefer-stable --prefer-dist --no-interaction --no-progress --no-suggest
- name: Run tests
run: ./vendor/bin/phpunit -c phpunit.xml
- name: Static analysis for source
run: ./vendor/bin/phpstan analyse -l max src
- name: Static analysis for tests
run: ./vendor/bin/phpstan analyse -l 5 -c .phpstan.test.neon test
- name: Code Style
run: ./vendor/bin/php-cs-fixer fix --dry-run --verbose --config .php-cs-fixer.dist.php ./src ./test