-
Notifications
You must be signed in to change notification settings - Fork 10
36 lines (36 loc) · 1.41 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
name: CI
on: [push, pull_request]
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
php-version: ['8.1', '8.3']
name: PHP ${{ matrix.php-version }}
steps:
- uses: actions/checkout@v2
- name: Install PHP
uses: shivammathur/setup-php@v2
with:
coverage: pcov
php-version: ${{ matrix.php-version }}
tools: pecl, composer:v2
extensions: mongodb-1.13
- name: Composer config
run: composer config --no-plugins allow-plugins.infection/extension-installer true
- name: Composer install
run: composer install --no-interaction --no-progress --no-suggest
- name: PHPUnit
run: ./vendor/bin/phpunit --coverage-clover coverage.xml
- name: PHPStan
run: ./vendor/bin/phpstan analyse --no-progress --no-interaction
- name: Infection
run: ./vendor/bin/infection --no-progress
env:
INFECTION_BADGE_API_KEY: ${{ secrets.INFECTION_BADGE_API_KEY }}
- name: Codecov
uses: codecov/codecov-action@v1
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: ./coverage.xml