Respect abort testing on failure flag

On regular commits we do not want to waste time running all test if
there is failures.

Change-Id: I050d191058293f4311268169eb26754349930129
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
This commit is contained in:
Toni Saario 2020-09-23 21:21:48 +03:00
parent 74146e0102
commit 19d2e61f87
2 changed files with 24 additions and 2 deletions

View File

@ -1,7 +1,18 @@
type: Group
instructions:
- type: EnvironmentVariable
variableName: CTEST_ARGS
variableValue: "-V --rerun-failed --force-new-ctest-process --repeat until-pass:5"
- type: AppendToEnvironmentVariable
variableName: CTEST_ARGS
variableValue: " --stop-on-failure"
enable_if:
condition: property
property: features
contains_value: AbortTestingOnFirstFailure
- type: ExecuteCommand
command: "{{.Env.TESTS_ENV_PREFIX}} ctest -V --rerun-failed --force-new-ctest-process --repeat until-pass:5"
command: "{{.Env.TESTS_ENV_PREFIX}} ctest {{.Env.CTEST_ARGS}}"
executeCommandArgumentSplitingBehavior: SplitAfterVariableSubstitution
ignoreExitCode: false
maxTimeInSeconds: 7200
maxTimeBetweenOutput: 900

View File

@ -1,7 +1,18 @@
type: Group
instructions:
- type: EnvironmentVariable
variableName: CTEST_ARGS
variableValue: "-V --rerun-failed --force-new-ctest-process"
- type: AppendToEnvironmentVariable
variableName: CTEST_ARGS
variableValue: " --stop-on-failure"
enable_if:
condition: property
property: features
contains_value: AbortTestingOnFirstFailure
- type: ExecuteCommand
command: "{{.Env.TESTS_ENV_PREFIX}} ctest -V --rerun-failed --force-new-ctest-process"
command: "{{.Env.TESTS_ENV_PREFIX}} ctest {{.Env.CTEST_ARGS}}"
executeCommandArgumentSplitingBehavior: SplitAfterVariableSubstitution
ignoreExitCode: true
maxTimeInSeconds: 7200
maxTimeBetweenOutput: 900