mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-24 16:42:05 +00:00
Use timeout from ci_config in stress tests
This commit is contained in:
parent
a2bfcabc99
commit
5f7839740d
@ -483,6 +483,7 @@ stateful_test_common_params = {
|
||||
stress_test_common_params = {
|
||||
"digest": stress_check_digest,
|
||||
"run_command": "stress_check.py",
|
||||
"timeout": 9000,
|
||||
}
|
||||
upgrade_test_common_params = {
|
||||
"digest": upgrade_check_digest,
|
||||
|
@ -14,7 +14,7 @@ from docker_images_helper import DockerImage, get_docker_image, pull_image
|
||||
from env_helper import REPO_COPY, REPORT_PATH, TEMP_PATH
|
||||
from get_robot_token import get_parameter_from_ssm
|
||||
from pr_info import PRInfo
|
||||
from report import ERROR, JobReport, TestResult, TestResults, read_test_results
|
||||
from report import ERROR, JobReport, TestResults, read_test_results
|
||||
from stopwatch import Stopwatch
|
||||
from tee_popen import TeePopen
|
||||
|
||||
@ -161,14 +161,9 @@ def run_stress_test(docker_image_name: str) -> None:
|
||||
)
|
||||
logging.info("Going to run stress test: %s", run_command)
|
||||
|
||||
timeout_expired = False
|
||||
timeout = 60 * 150
|
||||
with TeePopen(run_command, run_log_path, timeout=timeout) as process:
|
||||
with TeePopen(run_command, run_log_path) as process:
|
||||
retcode = process.wait()
|
||||
if process.timeout_exceeded:
|
||||
logging.info("Timeout expired for command: %s", run_command)
|
||||
timeout_expired = True
|
||||
elif retcode == 0:
|
||||
if retcode == 0:
|
||||
logging.info("Run successfully")
|
||||
else:
|
||||
logging.info("Run failed")
|
||||
@ -180,11 +175,6 @@ def run_stress_test(docker_image_name: str) -> None:
|
||||
result_path, server_log_path, run_log_path
|
||||
)
|
||||
|
||||
if timeout_expired:
|
||||
test_results.append(TestResult.create_check_timeout_expired(timeout))
|
||||
state = "failure"
|
||||
description = test_results[-1].name
|
||||
|
||||
JobReport(
|
||||
description=description,
|
||||
test_results=test_results,
|
||||
|
Loading…
Reference in New Issue
Block a user