summaryrefslogtreecommitdiff
path: root/share/spack/qa/setup.sh
diff options
context:
space:
mode:
authorTodd Gamblin <tgamblin@llnl.gov>2019-05-09 23:52:39 -0700
committerPeter Scheibel <scheibel1@llnl.gov>2019-05-11 02:23:22 +0900
commit3903658bfc8e53c89ebde593d762cb8fb732129a (patch)
treed766677106dd9351ce0884d8b09328a305386ce9 /share/spack/qa/setup.sh
parent85fa2dbe369aa6cd1fac64f214aa57668a535ec9 (diff)
downloadspack-3903658bfc8e53c89ebde593d762cb8fb732129a.tar.gz
spack-3903658bfc8e53c89ebde593d762cb8fb732129a.tar.bz2
spack-3903658bfc8e53c89ebde593d762cb8fb732129a.tar.xz
spack-3903658bfc8e53c89ebde593d762cb8fb732129a.zip
coverage: only run coverage for subset of unit tests
- Codecov cannot handle as many coverage reports as we are generating - as a result, our PR coverage pages have been broken for a while, and it's hard to tell people where to enhance their testing in PR reviews. - Scale back to only running coverage for 3.7 and 2.7 unit tests - This is *probably* better. We run the build tests for good measure, but we do not need to evaluate them for coverage. The coverage reports are about unit tests.
Diffstat (limited to 'share/spack/qa/setup.sh')
-rwxr-xr-xshare/spack/qa/setup.sh9
1 files changed, 5 insertions, 4 deletions
diff --git a/share/spack/qa/setup.sh b/share/spack/qa/setup.sh
index f6132c3ec9..6256269211 100755
--- a/share/spack/qa/setup.sh
+++ b/share/spack/qa/setup.sh
@@ -16,8 +16,12 @@ export SPACK_ROOT=$(realpath "$QA_DIR/../../..")
# Source the setup script
. "$SPACK_ROOT/share/spack/setup-env.sh"
+# by default coverage is off.
+coverage=""
+coverage_run=""
+
# Set up some variables for running coverage tests.
-if [[ "$TEST_SUITE" == "unit" || "$TEST_SUITE" == "build" ]]; then
+if [[ "$COVERAGE" == "true" ]]; then
# these set up coverage for Python
coverage=coverage
coverage_run="coverage run"
@@ -33,9 +37,6 @@ if [[ "$TEST_SUITE" == "unit" || "$TEST_SUITE" == "build" ]]; then
bashcov=$(realpath ${QA_DIR}/bashcov)
sed -i~ "s@#\!/bin/bash@#\!${bashcov}@" "$cc_script"
fi
-else
- coverage=""
- coverage_run=""
fi
#