From 95fd1419b0fb96d312b557abf3f5e2896475a3d9 Mon Sep 17 00:00:00 2001 From: Lewis Marshall Date: Mon, 5 Aug 2024 00:07:59 +0100 Subject: [PATCH] WIP test against the lmars-dev cluster Signed-off-by: Lewis Marshall --- test/ably/rest/restinit_test.py | 8 ++++---- test/ably/rest/restrequest_test.py | 4 ++-- test/ably/testapp.py | 6 +++--- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/test/ably/rest/restinit_test.py b/test/ably/rest/restinit_test.py index 10dd8282..649df1ec 100644 --- a/test/ably/rest/restinit_test.py +++ b/test/ably/rest/restinit_test.py @@ -79,9 +79,9 @@ def test_rest_host_and_environment(self): assert "rest.ably.io" == host, "Unexpected host mismatch %s" % host # environment: other - ably = AblyRest(token='foo', environment="sandbox") + ably = AblyRest(token='foo', environment="lmars-dev") host = ably.options.get_rest_host() - assert "sandbox-rest.ably.io" == host, "Unexpected host mismatch %s" % host + assert "lmars-dev-rest.ably.io" == host, "Unexpected host mismatch %s" % host # both, as per #TO3k2 with pytest.raises(ValueError): @@ -103,8 +103,8 @@ def test_fallback_hosts(self): assert sorted(aux) == sorted(ably.options.get_fallback_rest_hosts()) # Specify environment (RSC15g2) - ably = AblyRest(token='foo', environment='sandbox', http_max_retry_count=10) - assert sorted(Defaults.get_environment_fallback_hosts('sandbox')) == sorted( + ably = AblyRest(token='foo', environment='lmars-dev', http_max_retry_count=10) + assert sorted(Defaults.get_environment_fallback_hosts('lmars-dev')) == sorted( ably.options.get_fallback_rest_hosts()) # Fallback hosts and environment not specified (RSC15g3) diff --git a/test/ably/rest/restrequest_test.py b/test/ably/rest/restrequest_test.py index d0c9ad9d..8f58a5ee 100644 --- a/test/ably/rest/restrequest_test.py +++ b/test/ably/rest/restrequest_test.py @@ -101,8 +101,8 @@ async def test_timeout(self): await ably.request('GET', '/time', version=Defaults.protocol_version) await ably.close() - default_endpoint = 'https://sandbox-rest.ably.io/time' - fallback_host = 'sandbox-a-fallback.ably-realtime.com' + default_endpoint = 'https://lmars-dev-rest.ably.io/time' + fallback_host = 'lmars-dev-a-fallback.ably-realtime.com' fallback_endpoint = f'https://{fallback_host}/time' ably = await TestApp.get_ably_rest(fallback_hosts=[fallback_host]) with respx.mock: diff --git a/test/ably/testapp.py b/test/ably/testapp.py index 86741f3c..55b3c4d8 100644 --- a/test/ably/testapp.py +++ b/test/ably/testapp.py @@ -14,10 +14,10 @@ app_spec_local = json.loads(f.read()) tls = (os.environ.get('ABLY_TLS') or "true").lower() == "true" -rest_host = os.environ.get('ABLY_REST_HOST', 'sandbox-rest.ably.io') -realtime_host = os.environ.get('ABLY_REALTIME_HOST', 'sandbox-realtime.ably.io') +rest_host = os.environ.get('ABLY_REST_HOST', 'lmars-dev-rest.ably.io') +realtime_host = os.environ.get('ABLY_REALTIME_HOST', 'lmars-dev-realtime.ably.io') -environment = os.environ.get('ABLY_ENV', 'sandbox') +environment = os.environ.get('ABLY_ENV', 'lmars-dev') port = 80 tls_port = 443