CMake:Android:Coin: prioritize timeout from COIN_COMMAND_OUTPUT_TIMEOUT
... from CMake so that Coin doesn't end up killing the whole VM if aRows test gets stuck and instead allow androidtestrunner to cleanup and fetch the logs so we know what happened, and even potentially ending up re-run the test and succeeding if it was flaky. Also, since CMake sets the timeout during configuration time, coin needs to set COIN_COMMAND_OUTPUT_TIMEOUT under the build target where tests are configured, so this moves the setting of that env var from the test target to the build target. Change-Id: I9883ea1e98c93f79a088067518d09ca8acd5fdfd Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> (cherry picked from commit 3ee2ecd6bfdf3320e66628afa5d017783df2ee91) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org> (cherry picked from commit 5ebce47ac417c51e0a2a027eb873a91f1c703e16) (cherry picked from commit 97e4f9902e9133b8e512a8a6f3a9836641e8845d)
This commit is contained in:
parent
f931facd07
commit
eb8d1850c7
@ -749,8 +749,13 @@ endfunction()
|
||||
function(qt_internal_get_android_test_timeout input_timeout percentage output_timeout_var)
|
||||
set(actual_timeout "${input_timeout}")
|
||||
if(NOT actual_timeout)
|
||||
# Related: https://gitlab.kitware.com/cmake/cmake/-/issues/20450
|
||||
if(DART_TESTING_TIMEOUT)
|
||||
# we have coin ci timeout set use that to avoid having the emulator killed
|
||||
# so we can at least get some logs from the android test runner.
|
||||
set(coin_timeout $ENV{COIN_COMMAND_OUTPUT_TIMEOUT})
|
||||
if(coin_timeout)
|
||||
set(actual_timeout "${coin_timeout}")
|
||||
elseif(DART_TESTING_TIMEOUT)
|
||||
# Related: https://gitlab.kitware.com/cmake/cmake/-/issues/20450
|
||||
set(actual_timeout "${DART_TESTING_TIMEOUT}")
|
||||
elseif(CTEST_TEST_TIMEOUT)
|
||||
set(actual_timeout "${CTEST_TEST_TIMEOUT}")
|
||||
|
@ -83,21 +83,6 @@ instructions:
|
||||
env_var: CMAKE_MIN_SUPPORTED_BIN_PATH
|
||||
equals_value: null
|
||||
|
||||
- type: EnvironmentVariable
|
||||
variableName: COIN_COMMAND_OUTPUT_TIMEOUT
|
||||
variableValue: "900"
|
||||
disable_if:
|
||||
condition: property
|
||||
property: features
|
||||
contains_value: UseAddressSanitizer
|
||||
- type: EnvironmentVariable
|
||||
variableName: COIN_COMMAND_OUTPUT_TIMEOUT
|
||||
variableValue: "10800"
|
||||
enable_if:
|
||||
condition: property
|
||||
property: features
|
||||
contains_value: UseAddressSanitizer
|
||||
|
||||
- type: ExecuteCommand
|
||||
command: "{{.Env.TESTS_ENV_PREFIX}} ctest {{.Env.CTEST_ARGS}}"
|
||||
executeCommandArgumentSplitingBehavior: SplitAfterVariableSubstitution
|
||||
|
@ -587,3 +587,18 @@ instructions:
|
||||
condition: property
|
||||
property: host.os
|
||||
equals_value: Windows
|
||||
|
||||
- type: EnvironmentVariable
|
||||
variableName: COIN_COMMAND_OUTPUT_TIMEOUT
|
||||
variableValue: "900"
|
||||
disable_if:
|
||||
condition: property
|
||||
property: features
|
||||
contains_value: UseAddressSanitizer
|
||||
- type: EnvironmentVariable
|
||||
variableName: COIN_COMMAND_OUTPUT_TIMEOUT
|
||||
variableValue: "10800"
|
||||
enable_if:
|
||||
condition: property
|
||||
property: features
|
||||
contains_value: UseAddressSanitizer
|
||||
|
Loading…
x
Reference in New Issue
Block a user