Skip to content

Commit 25edf2c

Browse files
[STYLE] Refactor as discussed in review (- WIP PR #414 -)
* this work is related to GHI #130 Changes in file .github/actions/test-reporter-upload/action.yml: * refactored logic
1 parent 94899a7 commit 25edf2c

File tree

1 file changed

+6
-16
lines changed

1 file changed

+6
-16
lines changed

.github/actions/test-reporter-upload/action.yml

Lines changed: 6 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -230,24 +230,14 @@ runs:
230230
shell: bash
231231
run: |
232232
if [[ "${OS}" != "unknown" ]] ; then
233-
if [[ "${{ steps.output_upload_tools.outputs.can_upload_to_codecov }}" == "true" ]] ; then
234-
THE_RESULT="success"
235-
fi ;
236-
if [[ "${{ steps.output_upload_tools.outputs.can_upload_to_codeclimate }}" == "true" ]] ; then
237-
THE_RESULT="success"
238-
fi ;
239-
if [[ "${{ steps.output_upload_tools.outputs.can_upload_to_coveralls }}" == "true" ]] ; then
240-
THE_RESULT="success"
241-
fi ;
242-
if [[ "${{ steps.output_upload_tools.outputs.can_upload_to_deepsource }}" == "true" ]] ; then
233+
if [[ "${{ steps.output_upload_tools.outputs.can_upload_to_codecov }}" == "true" ]] || \
234+
[[ "${{ steps.output_upload_tools.outputs.can_upload_to_codeclimate }}" == "true" ]] || \
235+
[[ "${{ steps.output_upload_tools.outputs.can_upload_to_coveralls }}" == "true" ]] || \
236+
[[ "${{ steps.output_upload_tools.outputs.can_upload_to_deepsource }}" == "true" ]] ; then
243237
THE_RESULT="success"
244238
else
245-
if [[ "${THE_RESULT}" == "success" ]] ; then
246-
THE_RESULT="success"
247-
else
248-
THE_RESULT="failure"
249-
fi
250-
fi ;
239+
THE_RESULT="failure"
240+
fi
251241
else
252242
THE_RESULT="skipped"
253243
fi

0 commit comments

Comments
 (0)