Skip to content

Commit fa01feb

Browse files
author
MarcoFalke
committed
test: Remove ci timeout restriction in test_runner
1 parent 5bf45fe commit fa01feb

File tree

1 file changed

+3
-11
lines changed

1 file changed

+3
-11
lines changed

test/functional/test_runner.py

+3-11
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,8 @@
1919
import os
2020
import time
2121
import shutil
22-
import signal
23-
import sys
2422
import subprocess
23+
import sys
2524
import tempfile
2625
import re
2726
import logging
@@ -366,11 +365,10 @@ def main():
366365
args=passon_args,
367366
combined_logs_len=args.combinedlogslen,
368367
failfast=args.failfast,
369-
runs_ci=args.ci,
370368
use_term_control=args.ansi,
371369
)
372370

373-
def run_tests(*, test_list, src_dir, build_dir, tmpdir, jobs=1, enable_coverage=False, args=None, combined_logs_len=0, failfast=False, runs_ci, use_term_control):
371+
def run_tests(*, test_list, src_dir, build_dir, tmpdir, jobs=1, enable_coverage=False, args=None, combined_logs_len=0, failfast=False, use_term_control):
374372
args = args or []
375373

376374
# Warn if bitcoind is already running
@@ -412,7 +410,6 @@ def run_tests(*, test_list, src_dir, build_dir, tmpdir, jobs=1, enable_coverage=
412410
tmpdir=tmpdir,
413411
test_list=test_list,
414412
flags=flags,
415-
timeout_duration=40 * 60 if runs_ci else float('inf'), # in seconds
416413
use_term_control=use_term_control,
417414
)
418415
start_time = time.time()
@@ -497,12 +494,11 @@ class TestHandler:
497494
Trigger the test scripts passed in via the list.
498495
"""
499496

500-
def __init__(self, *, num_tests_parallel, tests_dir, tmpdir, test_list, flags, timeout_duration, use_term_control):
497+
def __init__(self, *, num_tests_parallel, tests_dir, tmpdir, test_list, flags, use_term_control):
501498
assert num_tests_parallel >= 1
502499
self.num_jobs = num_tests_parallel
503500
self.tests_dir = tests_dir
504501
self.tmpdir = tmpdir
505-
self.timeout_duration = timeout_duration
506502
self.test_list = test_list
507503
self.flags = flags
508504
self.num_running = 0
@@ -543,10 +539,6 @@ def get_next(self):
543539
time.sleep(.5)
544540
for job in self.jobs:
545541
(name, start_time, proc, testdir, log_out, log_err) = job
546-
if int(time.time() - start_time) > self.timeout_duration:
547-
# Timeout individual tests if timeout is specified (to stop
548-
# tests hanging and not providing useful output).
549-
proc.send_signal(signal.SIGINT)
550542
if proc.poll() is not None:
551543
log_out.seek(0), log_err.seek(0)
552544
[stdout, stderr] = [log_file.read().decode('utf-8') for log_file in (log_out, log_err)]

0 commit comments

Comments
 (0)