Skip to content
Snippets Groups Projects
Commit b7b62b9a authored by Ben Boeckel's avatar Ben Boeckel
Browse files

ci: avoid spawning tests into a busy machine

ParaView is very sensitive to machine load, so this should make testing
more reliable.
parent febb3fe2
No related branches found
No related tags found
No related merge requests found
......@@ -8,6 +8,11 @@ ctest_start(APPEND)
include(ProcessorCount)
ProcessorCount(nproc)
if (NOT "$ENV{CTEST_MAX_PARALLELISM}" STREQUAL "")
if (nproc GREATER "$ENV{CTEST_MAX_PARALLELISM}")
set(nproc "$ENV{CTEST_MAX_PARALLELISM}")
endif ()
endif ()
# Default to a reasonable test timeout.
set(CTEST_TEST_TIMEOUT 100)
......@@ -139,6 +144,7 @@ endif ()
ctest_test(APPEND
PARALLEL_LEVEL "${nproc}"
TEST_LOAD "${nproc}"
RETURN_VALUE test_result
EXCLUDE "${test_exclusions}"
REPEAT UNTIL_PASS:3)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment