Skip to content

Commit 06b9957

Browse files
committed
Upload Evergreen test results to codecov.io
1 parent 1d5e622 commit 06b9957

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

.evergreen/config/functions.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -159,6 +159,26 @@ functions:
159159
- command: attach.results
160160
params:
161161
file_location: "${DRIVERS_TOOLS}/results.json"
162+
- command: shell.exec
163+
params:
164+
working_dir: src
165+
script: |
166+
${PREPARE_SHELL}
167+
if [ -f test-results.xml ]; then
168+
curl -Os https://cli.codecov.io/latest/linux/codecov
169+
curl -Os https://cli.codecov.io/latest/linux/codecov.SHA256SUM
170+
shasum -a 256 -c codecov.SHA256SUM
171+
sudo chmod +x codecov
172+
./codecov upload-process \
173+
--report-type test_results \
174+
--disable-search \
175+
--fail-on-error \
176+
--token ${CODECOV_TOKEN} \
177+
--flag "${MONGODB_VERSION}-${TOPOLOGY}" \
178+
--file test-results.xml
179+
else
180+
echo "Skipping codecov test result upload"
181+
fi
162182
163183
"bootstrap mongo-orchestration":
164184
- command: shell.exec

0 commit comments

Comments
 (0)