From ec4faeebbf540aeacf7e538abd66111db421199f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A5vard=20Berland?= Date: Thu, 8 Feb 2024 15:02:32 +0100 Subject: [PATCH] Improve test robustness towards license failures --- tests/test_summary_restarts.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/test_summary_restarts.py b/tests/test_summary_restarts.py index 34dd7494..b4df1a39 100644 --- a/tests/test_summary_restarts.py +++ b/tests/test_summary_restarts.py @@ -125,9 +125,9 @@ def run_reservoir_simulator(eclipse_version: str, datafile: str) -> None: stdout=subprocess.PIPE, stderr=subprocess.PIPE, ) - if ( - result.returncode != 0 - and "LICENSE FAILURE" in result.stdout.decode() + result.stderr.decode() + aggregated_output = result.stdout.decode() + result.stderr.decode() + if result.returncode != 0 and ( + "LICENSE FAILURE" in aggregated_output or "LICENSE ERROR" in aggregated_output ): print("Eclipse failed due to license server issues. Retrying in 30 seconds.") time.sleep(30)