mirror of
https://github.com/neovim/neovim.git
synced 2025-09-13 06:48:17 +00:00
codecov: Submit test suite specific coverage
This commit is contained in:
@@ -1,8 +0,0 @@
|
|||||||
#!/usr/bin/env bash
|
|
||||||
|
|
||||||
set -e
|
|
||||||
set -o pipefail
|
|
||||||
|
|
||||||
if [[ -n "${GCOV}" ]]; then
|
|
||||||
bash <(curl -s https://codecov.io/bash) || echo 'codecov upload failed.'
|
|
||||||
fi
|
|
@@ -56,6 +56,10 @@ bin\nvim --version || goto :error
|
|||||||
:: Functional tests
|
:: Functional tests
|
||||||
mingw32-make functionaltest VERBOSE=1 || goto :error
|
mingw32-make functionaltest VERBOSE=1 || goto :error
|
||||||
|
|
||||||
|
if defined USE_GCOV (
|
||||||
|
C:\msys64\usr\bin\bash -lc "cd /c/projects/neovim; bash <(curl -s https://codecov.io/bash) -c -F functionaltest || echo 'codecov upload failed.'"
|
||||||
|
)
|
||||||
|
|
||||||
:: Old tests
|
:: Old tests
|
||||||
setlocal
|
setlocal
|
||||||
set PATH=%PATH%;C:\msys64\usr\bin
|
set PATH=%PATH%;C:\msys64\usr\bin
|
||||||
@@ -63,7 +67,7 @@ mingw32-make -C "%~dp0\..\src\nvim\testdir" VERBOSE=1
|
|||||||
endlocal
|
endlocal
|
||||||
|
|
||||||
if defined USE_GCOV (
|
if defined USE_GCOV (
|
||||||
C:\msys64\usr\bin\bash -lc "cd /c/projects/neovim; bash <(curl -s https://codecov.io/bash) || echo 'codecov upload failed.'"
|
C:\msys64\usr\bin\bash -lc "cd /c/projects/neovim; bash <(curl -s https://codecov.io/bash) -c -F oldtest || echo 'codecov upload failed.'"
|
||||||
)
|
)
|
||||||
|
|
||||||
:: Build artifacts
|
:: Build artifacts
|
||||||
|
@@ -1,6 +1,15 @@
|
|||||||
. "${CI_DIR}/common/build.sh"
|
. "${CI_DIR}/common/build.sh"
|
||||||
. "${CI_DIR}/common/suite.sh"
|
. "${CI_DIR}/common/suite.sh"
|
||||||
|
|
||||||
|
submit_coverage() {
|
||||||
|
if [ -n "${GCOV}" ]; then
|
||||||
|
if curl --fail --output codecov.bash --silent https://codecov.io/bash; then
|
||||||
|
bash codecov.bash -c -F "$1" || echo "codecov upload failed."
|
||||||
|
rm -f codecov.bash
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
print_core() {
|
print_core() {
|
||||||
local app="$1"
|
local app="$1"
|
||||||
local core="$2"
|
local core="$2"
|
||||||
@@ -82,6 +91,7 @@ run_unittests() {(
|
|||||||
if ! build_make unittest ; then
|
if ! build_make unittest ; then
|
||||||
fail 'unittests' F 'Unit tests failed'
|
fail 'unittests' F 'Unit tests failed'
|
||||||
fi
|
fi
|
||||||
|
submit_coverage unittest
|
||||||
check_core_dumps "$(which luajit)"
|
check_core_dumps "$(which luajit)"
|
||||||
exit_suite
|
exit_suite
|
||||||
)}
|
)}
|
||||||
@@ -92,6 +102,7 @@ run_functionaltests() {(
|
|||||||
if ! build_make ${FUNCTIONALTEST}; then
|
if ! build_make ${FUNCTIONALTEST}; then
|
||||||
fail 'functionaltests' F 'Functional tests failed'
|
fail 'functionaltests' F 'Functional tests failed'
|
||||||
fi
|
fi
|
||||||
|
submit_coverage functionaltest
|
||||||
asan_check "${LOG_DIR}"
|
asan_check "${LOG_DIR}"
|
||||||
valgrind_check "${LOG_DIR}"
|
valgrind_check "${LOG_DIR}"
|
||||||
check_core_dumps
|
check_core_dumps
|
||||||
@@ -105,6 +116,7 @@ run_oldtests() {(
|
|||||||
reset
|
reset
|
||||||
fail 'oldtests' F 'Legacy tests failed'
|
fail 'oldtests' F 'Legacy tests failed'
|
||||||
fi
|
fi
|
||||||
|
submit_coverage oldtest
|
||||||
asan_check "${LOG_DIR}"
|
asan_check "${LOG_DIR}"
|
||||||
valgrind_check "${LOG_DIR}"
|
valgrind_check "${LOG_DIR}"
|
||||||
check_core_dumps
|
check_core_dumps
|
||||||
|
Reference in New Issue
Block a user