Skip to content

Commit 63aeff8

Browse files
committed
Fixed tests
1 parent dc4d3f1 commit 63aeff8

3 files changed

Lines changed: 6 additions & 10 deletions

File tree

exasol/saas/client/api_access.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -255,6 +255,10 @@ def still_exists() -> bool:
255255
raise DatabaseDeleteTimeout
256256

257257
def _wait_for_delete(self, database_id: str):
258+
# if http
259+
# "status": 400,
260+
# "message": "Operation is not allowed:The cluster is not in a proper state!",
261+
# then wait a bit an retry
258262
deletable = [
259263
Status.RUNNING,
260264
Status.SCALING,
@@ -321,6 +325,7 @@ def database(
321325
try:
322326
db = self.create_database(name, idle_time=idle_time)
323327
yield db
328+
wait_for_delete_clearance()
324329
finally:
325330
db_repr = f"{db.name} with ID {db.id}" if db else None
326331
if db and not keep:

test/integration/connection_test.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
from exasol.saas.client.api_access import get_connection_params
55

66

7-
@pytest.mark.slow
87
def test_get_connection_params_with_id(
98
saas_host, saas_pat, saas_account_id, operational_saas_database_id, allow_connection
109
):
@@ -23,7 +22,6 @@ def test_get_connection_params_with_id(
2322
assert result == [(1,)]
2423

2524

26-
@pytest.mark.slow
2725
def test_get_connection_params_with_name(
2826
saas_host,
2927
saas_pat,

test/integration/databases_test.py

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
from exasol.saas.client import PROMISING_STATES
1010
from exasol.saas.client.api_access import (
1111
get_connection_params,
12+
timestamp_name,
1213
)
1314

1415

@@ -66,11 +67,3 @@ def test_get_connection(api_access, local_name):
6667
clusters = api_access.clusters(db.id)
6768
connection = api_access.get_connection(db.id, clusters[0].id)
6869
assert connection.db_username is not None and connection.port == 8563
69-
70-
71-
def test_dummy():
72-
"""
73-
Dummy test to prevent empty set of test cases to be interpreted as
74-
failure.
75-
"""
76-
pass

0 commit comments

Comments
 (0)