Skip to content

Commit 21f6c0f

Browse files
author
nix
committed
added deployment of tests coverage to pages
1 parent 121b901 commit 21f6c0f

File tree

1 file changed

+15
-1
lines changed

1 file changed

+15
-1
lines changed

.github/workflows/quality-assurance.yml

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,19 @@ on:
66

77
permissions:
88
contents: read
9+
pages: write
10+
id-token: write
911

1012
jobs:
1113
unit-tests:
12-
name: PHPUnit tests (with coverage, on PHP ${{ matrix.php }})
14+
name: PHPUnit tests + cov. (on PHP ${{ matrix.php }})
1315
runs-on: ubuntu-latest
1416
strategy:
1517
matrix:
1618
php: [ '8.2', '8.3', '8.4', '8.5' ]
19+
environment:
20+
name: github-pages
21+
url: '${{ steps.deployment.outputs.page_url }}/coverage/php-${{ matrix.php }}'
1722
steps:
1823
- name: 'Checkout'
1924
uses: actions/checkout@v4
@@ -24,6 +29,15 @@ jobs:
2429
coverage: xdebug
2530
- run: ./composer.phar install -n --no-progress -o
2631
- run: ./composer.phar test+coverage
32+
- name: 'Setup Pages'
33+
uses: actions/configure-pages@v5
34+
- name: 'Upload results (${{ matrix.php }})'
35+
uses: actions/upload-pages-artifact@v3
36+
with:
37+
path: 'tests-output/coverage'
38+
- name: 'Deploy to GitHub pages (${{ matrix.php }})'
39+
id: deployment
40+
uses: actions/deploy-pages@v4
2741
static-analysis:
2842
name: PHPStan checks (on PHP ${{ matrix.php }})
2943
runs-on: ubuntu-latest

0 commit comments

Comments
 (0)