-
-
Notifications
You must be signed in to change notification settings - Fork 0
83 lines (68 loc) · 1.91 KB
/
commit.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
name: Continuous Integration
on: [push]
jobs:
phpunit:
name: Unit Tests
runs-on: ubuntu-latest
steps:
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: 8.0
coverage: xdebug
tools: composer:v2
- name: Checkout Repository
uses: actions/checkout@v2
- name: Install Dependencies
run: composer install
- name: Test
run: vendor/bin/phpunit tests --testdox --coverage-clover coverage.xml
- name: Upload to CodeCov
uses: codecov/codecov-action@v1
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: coverage.xml
fail_ci_if_error: true
phpstan:
name: Static Analysis Check
runs-on: ubuntu-latest
container:
image: davidalger/php:8.0
steps:
- name: Checkout Repository
uses: actions/checkout@v2
- name: Install Dependencies
run: composer2 install
- name: Run PHPStan
run: vendor/bin/phpstan
phpcs:
name: Code Style (PSR-12)
runs-on: ubuntu-latest
container:
image: davidalger/php:8.0
steps:
- name: Checkout Repository
uses: actions/checkout@v2
- name: Install Dependencies
run: composer2 install
- name: PHP Code Sniffer
run: vendor/bin/phpcs
infection:
name: Infection Check
runs-on: ubuntu-latest
continue-on-error: true
steps:
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: 8.0
coverage: xdebug
tools: composer:v2
- name: Checkout Repository
uses: actions/checkout@v2
- name: Install dependencies
run: composer install
- name: Check for Mutants
env:
INFECTION_BADGE_API_KEY: ${{ secrets.STRYKER_TOKEN }}
run: vendor/bin/infection --threads=$(nproc) --no-progress --logger-github