-
Notifications
You must be signed in to change notification settings - Fork 17
86 lines (86 loc) · 2.58 KB
/
ci.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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
name: CI
on: [push, pull_request]
jobs:
cs-check:
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@master
- name: setup
uses: shivammathur/[email protected]
with:
php-version: 8.2
coverage: none
- name: install PHP CS Fixer
run: 'composer install -n --prefer-dist --optimize-autoloader --working-dir=tools/php-cs-fixer'
- name: 'php-cs-fixer check'
run: 'tools/php-cs-fixer/vendor/bin/php-cs-fixer fix --config=tools/php-cs-fixer/.php-cs-fixer.php --dry-run --diff'
phpstan:
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@master
- name: cache-composer
uses: actions/cache@v2
with:
path: ~/.composer/cache/
key: composer-${{ github.sha }}
- name: setup
uses: shivammathur/[email protected]
with:
php-version: 8.3
coverage: none
- name: composer install
run: composer update --prefer-stable
- name: install phpstan
run: 'composer install -n --prefer-dist --optimize-autoloader --working-dir=tools/phpstan'
- name: 'phpstan check'
run: 'tools/phpstan/vendor/bin/phpstan analyse --configuration=tools/phpstan/phpstan.neon'
tests:
runs-on: ubuntu-latest
name: tests
strategy:
fail-fast: false
matrix:
php-versions:
- 8.2
- 8.3
steps:
- name: checkout
uses: actions/checkout@master
- name: cache-composer
uses: actions/cache@v2
with:
path: ~/.composer/cache/
key: composer-${{ github.sha }}
- name: setup
uses: shivammathur/[email protected]
with:
php-version: '${{ matrix.php-versions }}'
coverage: none
extensions: mbstring, fileinfo, json, intl, dom
- name: composer install
run: composer update --prefer-stable
- name: tests
run: vendor/bin/phpunit
tests-lowest:
runs-on: ubuntu-latest
name: tests-lowest
steps:
- name: checkout
uses: actions/checkout@master
- name: cache-composer
uses: actions/cache@v2
with:
path: ~/.composer/cache/
key: composer-${{ github.sha }}
- name: setup
uses: shivammathur/[email protected]
with:
php-version: 8.2
coverage: none
extensions: mbstring, fileinfo, json, intl, dom
- name: composer install
run: composer update --prefer-stable --prefer-lowest
- name: tests
run: vendor/bin/phpunit