-
Notifications
You must be signed in to change notification settings - Fork 53
53 lines (43 loc) · 1.42 KB
/
Copy pathci.yml
File metadata and controls
53 lines (43 loc) · 1.42 KB
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
name: ci
on: [push, pull_request, release]
jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
php-versions: ['8.0', '8.1']
os: [ubuntu-18.04, ubuntu-20.04]
name: PHP ${{ matrix.php-versions }} Test
env:
PHP_CS_FIXER_IGNORE_ENV: 1
steps:
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-versions }}
extensions: mbstring
coverage: xdebug
- name: Validate Composer
run: composer validate --strict
- name: Install Composer Dependencies PHP
run: composer install --no-interaction --prefer-dist
- name: Run Tests
run: composer run-script pipeline
env:
STRYKER_DASHBOARD_API_KEY: ${{ secrets.STRYKER_DASHBOARD_API_KEY }}
- name: Code Coverage
run: bash <(curl -s https://codecov.io/bash)
- name: Fix Code Coverage File Paths
run: sed -i -e 's/\/home\/runner\/work\/ReallySimpleJWT\/ReallySimpleJWT\///g' coverage.xml
- name: Fix Test Report File Paths
run: sed -i -e 's/\/home\/runner\/work\/ReallySimpleJWT\/ReallySimpleJWT\///g' test-report.xml
- name: SonarCloud Scan
uses: sonarsource/sonarcloud-github-action@v1.6
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}