@@ -203,14 +203,39 @@ jobs:
203203 exit 1
204204 fi
205205
206+ Coverage_Fake :
207+ runs-on : ubuntu-latest
208+ needs : [Nemo_CICD_Test, pre-flight]
209+ if : |
210+ (
211+ needs.pre-flight.outputs.docs_only == 'true'
212+ || needs.pre-flight.outputs.is_deployment_workflow == 'true'
213+ )
214+ && needs.pre-flight.outputs.is_ci_workload == 'false'
215+ && !cancelled()
216+ environment : nemo-ci
217+ steps :
218+ - name : Generate fake coverage report
219+ uses : actions/github-script@v6
220+ with :
221+ github-token : ${{ secrets.PAT }}
222+ script : |
223+ await github.rest.repos.createCommitStatus({
224+ owner: context.repo.owner,
225+ repo: context.repo.repo,
226+ sha: context.sha,
227+ state: 'success',
228+ description: 'No code changes - coverage check skipped',
229+ context: 'codecov/patch'
230+ });
231+
206232 Coverage :
207233 runs-on : ubuntu-latest
208234 needs : [pre-flight, Nemo_CICD_Test]
209235 if : |
210- needs.pre-flight.outputs.docs_only == 'false'
211- && (
212- success()
213- || needs.Nemo_CICD_Test.result == 'success'
236+ (
237+ (needs.pre-flight.outputs.is_ci_workload == 'true' && !failure())
238+ || success()
214239 )
215240 && !cancelled()
216241 strategy :
@@ -252,13 +277,3 @@ jobs:
252277 path : |
253278 .coverage
254279 include-hidden-files : true
255-
256- codecov-placeholder :
257- name : codecov/patch
258- needs : [pre-flight]
259- if : needs.pre-flight.outputs.docs_only == 'true'
260- runs-on : ubuntu-latest
261- steps :
262- - name : codecov_placeholder
263- run : |
264- echo "This is a placeholder status check for when no tests are ran but the codecov status is expected"
0 commit comments