@@ -84,11 +84,34 @@ jobs:
84
84
path : |
85
85
~/Library/Developer/Xcode/DerivedData/Parse-*/Logs/Test
86
86
~/Library/Developer/Xcode/DerivedData/**/Logs/Build
87
- - name : Upload Coverage
88
-
87
+ - name : Install test parsing dependencies
88
+ if : matrix.script == 'test:ios'
89
+ # Workaround as codecov cannot parse xcresult files;
90
+ # https://github.com/codecov/uploader/issues/1078
91
+ # https://github.com/codecov/codecov-action/issues/1367
92
+ run : |
93
+ brew install a7ex/homebrew-formulae/xcresultparser
94
+ - name : Convert Xcode test results for code coverage upload
95
+ if : matrix.script == 'test:ios'
96
+ env :
97
+ COVERAGE_PATH : ${{ github.workspace }}/build/${{ matrix.script }}-coverage.xml
98
+ run : |
99
+ COVERAGE_PATH=${COVERAGE_PATH//:/-}
100
+ echo COVERAGE_PATH=$COVERAGE_PATH >> $GITHUB_ENV
101
+ echo "TEST_RESULTS: $TEST_RESULTS"
102
+ echo "COVERAGE_PATH: $COVERAGE_PATH"
103
+ set -o pipefail && \
104
+ xcresultparser --output-format cobertura \
105
+ "$TEST_RESULTS" >"$COVERAGE_PATH"
106
+ - name : Upload code coverage
107
+ if : matrix.script == 'test:ios'
108
+ uses : codecov/codecov-action@v4
89
109
with :
90
- xcode : true
91
- xcode_archive_path : ${{ env.TEST_RESULTS }}
110
+ # Set to `true` once codecov token bug is fixed; https://github.com/parse-community/parse-server/issues/9129
111
+ fail_ci_if_error : false
112
+ token : ${{ secrets.CODECOV_TOKEN }}
113
+ plugin : xcode
114
+ file : ${{ env.COVERAGE_PATH }}
92
115
docs :
93
116
runs-on : macos-13
94
117
timeout-minutes : 15
0 commit comments