53
53
symfony-version : ' 5.4'
54
54
steps :
55
55
- name : Check out code
56
- uses : actions/checkout@v2
56
+ uses : actions/checkout@v3
57
57
58
58
- name : Enable coverage
59
59
if : ${{ matrix.php-version == '8.1' }}
73
73
74
74
- name : Setup cache
75
75
id : cache
76
- uses : actions/cache@v2
76
+ uses : actions/cache@v3
77
77
with :
78
78
path : |
79
79
~/.composer
@@ -105,6 +105,11 @@ jobs:
105
105
- name : Tests
106
106
run : make test-unit && make test-functional
107
107
108
+ # Upload to codacy first as codecov action always remove coverage files despite move_coverage_to_trash at false
109
+ - name : Upload coverages to Codacy
110
+ if : ${{ env.COVERAGE_TYPE == 'xdebug' }}
111
+ run : ${{ env.CODACY_BIN }} report -r build/coverage-phpunit/unit.clover -r build/coverage-behat/clover.xml -r build/coverage-phpunit/functional.clover -t ${{ secrets.CODACY_PROJECT_TOKEN }} --partial
112
+
108
113
# See the reports at https://codecov.io/gh/yoanm/symfony-jsonrpc-http-server
109
114
- name : Upload unit tests coverage to codecov
110
115
if : ${{ env.COVERAGE_TYPE == 'xdebug' }}
@@ -114,6 +119,8 @@ jobs:
114
119
name : " unit-tests-${{ matrix.php-version }}-${{ matrix.symfony-version }}"
115
120
flags : " unit-tests,php-${{ matrix.php-version }},sf-${{ matrix.symfony-version }}"
116
121
fail_ci_if_error : true
122
+ move_coverage_to_trash : false
123
+ verbose : ${{ runner.debug == '1' }}
117
124
118
125
- name : Upload functional tests coverage to codecov
119
126
if : ${{ env.COVERAGE_TYPE == 'xdebug' }}
@@ -123,17 +130,15 @@ jobs:
123
130
name : " functional-tests-${{ matrix.php-version }}-${{ matrix.symfony-version }}"
124
131
flags : " functional-tests,php-${{ matrix.php-version }},sf-${{ matrix.symfony-version }}"
125
132
fail_ci_if_error : true
126
-
127
- - name : Upload coverages to Codacy
128
- if : ${{ env.COVERAGE_TYPE == 'xdebug' }}
129
- run : ${{ env.CODACY_BIN }} report -r build/coverage-phpunit/unit.clover -r build/coverage-behat/clover.xml -r build/coverage-phpunit/functional.clover -t ${{ secrets.CODACY_PROJECT_TOKEN }} --partial
133
+ move_coverage_to_trash : false
134
+ verbose : ${{ runner.debug == '1' }}
130
135
131
136
static-checks :
132
137
name : Static checks
133
138
runs-on : ubuntu-latest
134
139
needs : [ tests ]
135
140
steps :
136
- - uses : actions/checkout@v2
141
+ - uses : actions/checkout@v3
137
142
138
143
- name : Setup PHP 8.1
139
144
uses : shivammathur/setup-php@v2
@@ -147,7 +152,7 @@ jobs:
147
152
148
153
- name : Setup cache
149
154
id : cache
150
- uses : actions/cache@v2
155
+ uses : actions/cache@v3
151
156
with :
152
157
path : |
153
158
~/.composer
@@ -171,7 +176,7 @@ jobs:
171
176
steps :
172
177
- name : Setup cache
173
178
id : cache
174
- uses : actions/cache@v2
179
+ uses : actions/cache@v3
175
180
with :
176
181
path : |
177
182
${{ env.CODACY_CACHE_PATH }}
@@ -213,7 +218,7 @@ jobs:
213
218
214
219
steps :
215
220
- name : Check out code
216
- uses : actions/checkout@v2
221
+ uses : actions/checkout@v3
217
222
218
223
- name : Setup PHP ${{ matrix.php-version }}
219
224
uses : shivammathur/setup-php@v2
@@ -227,7 +232,7 @@ jobs:
227
232
228
233
- name : Setup cache
229
234
id : cache
230
- uses : actions/cache@v2
235
+ uses : actions/cache@v3
231
236
with :
232
237
path : |
233
238
~/.composer
0 commit comments