Skip to content
This repository was archived by the owner on Dec 27, 2023. It is now read-only.

Commit 2a99de2

Browse files
committed
Check suite timeout before running tests
Sometimes the first suite test can be really long. With this patch we take into account suite timeout even for that one. Signed-off-by: Andrea Cervesato <[email protected]>
1 parent 4998fd1 commit 2a99de2

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

ltp/dispatcher.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -456,6 +456,9 @@ def _run_suite(
456456
if self._stop:
457457
break
458458

459+
if time.time() - start_t >= self._suite_timeout:
460+
timed_out = True
461+
459462
if timed_out or interrupt:
460463
# after suite timeout treat all tests left as skipped tests
461464
result = TestResults(

0 commit comments

Comments
 (0)