File tree Expand file tree Collapse file tree 3 files changed +45
-2
lines changed Expand file tree Collapse file tree 3 files changed +45
-2
lines changed Original file line number Diff line number Diff line change
1
+ name : CI
2
+
3
+ on :
4
+ push :
5
+ branches : [ main ]
6
+ pull_request :
7
+ branches : [ main ]
8
+
9
+ jobs :
10
+ test :
11
+ runs-on : ubuntu-latest
12
+
13
+ strategy :
14
+ matrix :
15
+ php-version : ['8.3']
16
+
17
+ steps :
18
+ - uses : actions/checkout@v4
19
+
20
+ - name : Setup PHP
21
+ uses : shivammathur/setup-php@v2
22
+ with :
23
+ php-version : ${{ matrix.php-version }}
24
+ extensions : gmp, xdebug
25
+ coverage : xdebug
26
+
27
+ - name : Install dependencies
28
+ run : composer install --prefer-dist --no-progress
29
+
30
+ - name : Run PHPStan
31
+ run : composer stan
32
+
33
+ - name : Run tests with coverage
34
+ run : composer coverage
35
+
36
+ - name : Upload coverage to Codecov
37
+ uses : codecov/codecov-action@v3
38
+ with :
39
+ file : ./coverage.xml
40
+ fail_ci_if_error : true
Original file line number Diff line number Diff line change 1
1
# blibio/combinatorics
2
2
3
3
[ ![ Software License] [ badge-license ]] [ license ]
4
+ [ ![ Coverage Status] [ badge-coverage ]] [ coverage ]
4
5
5
6
Simple PHP 8.3+ [ generators] [ ] to create:
6
7
@@ -41,4 +42,6 @@ The blibio/combinatorics library is copyright © Stephan Six and licensed for us
41
42
[ combinations ] : https://en.wikipedia.org/wiki/Combination
42
43
[ permutations ] : https://en.wikipedia.org/wiki/Permutation
43
44
[ badge-license ] : https://img.shields.io/badge/license-MIT-brightgreen.svg?style=flat-square
44
- [ license ] : https://github.com/blibio/combinatorics/blob/main/LICENSE
45
+ [ badge-coverage ] : https://codecov.io/gh/blibio/combinatorics/branch/main/graph/badge.svg
46
+ [ license ] : https://github.com/blibio/combinatorics/blob/main/LICENSE
47
+ [ coverage ] : https://codecov.io/gh/blibio/combinatorics
Original file line number Diff line number Diff line change 50
50
"scripts" : {
51
51
"test" : " phpunit" ,
52
52
"stan" : " phpstan analyse" ,
53
- "coverage" : " XDEBUG_MODE=coverage phpunit --coverage-html coverage-html --coverage-text" ,
53
+ "coverage" : " XDEBUG_MODE=coverage phpunit --coverage-html coverage-html --coverage-text --coverage-clover coverage.xml " ,
54
54
"coverage-text" : " XDEBUG_MODE=coverage phpunit --coverage-text" ,
55
55
"cs-fix" : " php-cs-fixer fix" ,
56
56
"cs-check" : " php-cs-fixer fix --dry-run --diff"
You can’t perform that action at this time.
0 commit comments