-
Notifications
You must be signed in to change notification settings - Fork 0
68 lines (68 loc) · 1.83 KB
/
build.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
name: build
on:
pull_request:
paths-ignore:
- '**.md'
push:
branches:
- master
paths-ignore:
- '**.md'
jobs:
cs:
runs-on: ubuntu-latest
name: Code style
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install PHP
uses: shivammathur/setup-php@v2
with:
php-version: 8.1
tools: composer:v2
- name: Install dependences
run: composer update --no-ansi --no-interaction --no-progress --prefer-dist
- name: Show dependences
run: composer show
- name: Run phpcs
run: composer check-style
analysis:
runs-on: ubuntu-latest
name: Static analysis
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install PHP
uses: shivammathur/setup-php@v2
with:
php-version: 8.1
tools: composer:v2
coverage: xdebug
- name: Install dependences
run: composer update --no-ansi --no-interaction --no-progress --prefer-dist
- name: Show dependences
run: composer show
- name: Run phpstan
run: composer stan
tests:
runs-on: ${{ matrix.operating-system }}
strategy:
max-parallel: 15
matrix:
operating-system: [ ubuntu-latest ]
php-versions: [ '7.3', '7.4', '8.0', '8.1' ]
name: Unit tests on PHP ${{ matrix.php-versions }}
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-versions }}
tools: composer:v2
- name: Install dependences
run: composer update --no-ansi --no-interaction --no-progress --prefer-dist
- name: Show dependences
run: composer show
- name: Run phpunit
run: composer test