2024-11-15 11:48:39 +00:00
|
|
|
from test_cases import StatusBackend
|
2024-10-07 15:40:18 +00:00
|
|
|
import pytest
|
2024-10-11 08:08:39 +00:00
|
|
|
|
2024-10-07 15:40:18 +00:00
|
|
|
|
|
|
|
@pytest.mark.create_account
|
|
|
|
@pytest.mark.rpc
|
2024-10-23 19:48:33 +00:00
|
|
|
class TestInitialiseApp:
|
2024-10-07 15:40:18 +00:00
|
|
|
|
|
|
|
@pytest.mark.init
|
2024-11-15 11:48:39 +00:00
|
|
|
def test_init_app(self):
|
|
|
|
|
|
|
|
await_signals = [
|
|
|
|
|
|
|
|
"mediaserver.started",
|
|
|
|
"node.started",
|
|
|
|
"node.ready",
|
|
|
|
"node.login",
|
|
|
|
]
|
|
|
|
|
|
|
|
backend_client = StatusBackend(await_signals)
|
|
|
|
backend_client.init_status_backend()
|
|
|
|
backend_client.restore_account_and_login()
|
2024-10-07 15:40:18 +00:00
|
|
|
|
|
|
|
assert backend_client is not None
|
2024-10-29 12:10:48 +00:00
|
|
|
|
|
|
|
backend_client.verify_json_schema(
|
|
|
|
backend_client.wait_for_signal("mediaserver.started"), "signal_mediaserver_started")
|
|
|
|
backend_client.verify_json_schema(
|
|
|
|
backend_client.wait_for_signal("node.started"), "signal_node_started")
|
|
|
|
backend_client.verify_json_schema(
|
|
|
|
backend_client.wait_for_signal("node.ready"), "signal_node_ready")
|
|
|
|
backend_client.verify_json_schema(
|
|
|
|
backend_client.wait_for_signal("node.login"), "signal_node_login")
|