-
Notifications
You must be signed in to change notification settings - Fork 2
38 lines (36 loc) · 1.25 KB
/
ci-unit-test-coverage.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
name: Unit Test Coverage Report
on:
- push
- fork
- pull_request
jobs:
coverage:
runs-on: ubuntu-latest
name: "Generate unit test coverage report for PHP ${{ matrix.php-version }}"
env:
XDEBUG_MODE: coverage
steps:
- uses: actions/checkout@v2
- name: Cache Composer dependencies
uses: actions/cache@v2
with:
path: /tmp/composer-cache
key: ${{ runner.os }}-${{ hashFiles('**/composer.lock') }}
- uses: shivammathur/setup-php@v2
with:
php-version: '8.3'
extensions: xdebug
tools: composer:v2
- run: composer install --ignore-platform-req=php
shell: bash
- run: composer test:coverage:xml
shell: bash
- uses: paambaati/[email protected]
env:
CC_TEST_REPORTER_ID: 203d856fbc3ebebe66cc94cccde4429973298c7fb919df64a1557850cc9c8345
with:
coverageLocations: coverage.xml:clover
- uses: actions/upload-artifact@v2
with:
name: coverage.xml
path: coverage.xml