mirror of
https://github.com/logos-messaging/logos-messaging-interop-tests.git
synced 2026-01-10 09:53:12 +00:00
tweaks for parallel run
This commit is contained in:
parent
806d7941f6
commit
d50b612ece
2
.github/workflows/test.yml
vendored
2
.github/workflows/test.yml
vendored
@ -49,7 +49,7 @@ jobs:
|
||||
- run: pip install -r requirements.txt
|
||||
|
||||
- name: Run tests
|
||||
run: pytest -n 5 --reruns 3 --alluredir=allure-results
|
||||
run: pytest -n 4 --reruns 2 --alluredir=allure-results
|
||||
|
||||
- name: Get allure history
|
||||
if: always()
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
import os
|
||||
import logging
|
||||
from time import sleep
|
||||
from tenacity import retry, stop_after_delay, wait_fixed
|
||||
from src.node.api_clients.rpc import RPC
|
||||
from src.node.api_clients.rest import REST
|
||||
@ -71,6 +72,7 @@ class WakuNode:
|
||||
"Started container from image %s. RPC: %s REST: %s WebSocket: %s", self._image_name, self._rpc_port, self._rest_port, self._websocket_port
|
||||
)
|
||||
DS.waku_nodes.append(self)
|
||||
sleep(1) # if we fire requests to soon after starting the node will sometimes fail to start correctly
|
||||
try:
|
||||
self.ensure_ready()
|
||||
except Exception as e:
|
||||
@ -84,7 +86,7 @@ class WakuNode:
|
||||
self._container.stop()
|
||||
logger.debug("Container stopped.")
|
||||
|
||||
@retry(stop=stop_after_delay(5), wait=wait_fixed(0.05), reraise=True)
|
||||
@retry(stop=stop_after_delay(10), wait=wait_fixed(0.1), reraise=True)
|
||||
def ensure_ready(self):
|
||||
self.info()
|
||||
logger.debug("RPC service is ready.")
|
||||
|
||||
@ -27,7 +27,7 @@ class StepsRelay:
|
||||
self.node2.set_subscriptions([self.test_pubsub_topic])
|
||||
|
||||
@pytest.fixture(scope="function", autouse=True)
|
||||
@retry(stop=stop_after_delay(40), wait=wait_fixed(1), reraise=True)
|
||||
@retry(stop=stop_after_delay(120), wait=wait_fixed(1), reraise=True)
|
||||
def wait_for_network_to_warm_up(self):
|
||||
message = {"payload": to_base64(self.test_payload), "contentTopic": self.test_content_topic, "timestamp": int(time() * 1e9)}
|
||||
try:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user