From a76e4c88f744940fe8c380c5a6370e0fe2e87539 Mon Sep 17 00:00:00 2001 From: "Wiktor S. Ovalle Correa" Date: Tue, 23 Feb 2021 11:07:20 +0100 Subject: [PATCH] [EGD-5737] Temporary fix Check if we have a race here --- test/pytest/conftest.py | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/test/pytest/conftest.py b/test/pytest/conftest.py index acebdf1bcd3ef5b18230eaec0080a8d276ff90b1..04eed2383cd50f0d15ce8e14938b23f0b8fa0d30 100644 --- a/test/pytest/conftest.py +++ b/test/pytest/conftest.py @@ -94,6 +94,19 @@ def harness(request): pytest.exit("not a valid sim pts entry!") harness = Harness(port_name) + + ''' + Wait for endpoints to initialize + ''' + testbody = {"ui": True, "getWindow": True} + result = None + with utils.Timeout.limit(seconds=305): + while not result: + try: + result = harness.endpoint_request("developerMode", "get", testbody) + except ValueError: + log.info("Endpoints not ready..") + except utils.Timeout: pytest.exit("couldn't find any viable port. exiting") else: