Skip to content

Commit

Permalink
#279 Increased the database time-out [run-notebook-tests]
Browse files Browse the repository at this point in the history
  • Loading branch information
ahsimb committed Jun 6, 2024
1 parent 721b08b commit 9ccdfc2
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions test/notebooks/notebook_test_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
import string
import textwrap
from contextlib import contextmanager, ExitStack
from datetime import timedelta
import os

import pytest
Expand Down Expand Up @@ -160,11 +161,15 @@ def access_to_temp_saas_secret_store(tmp_path_factory) -> Tuple[Path, str]:

with ExitStack() as stack:
client = stack.enter_context(create_saas_client(
secrets.get(CKey.saas_url), secrets.get(CKey.saas_token)))
api_access = OpenApiAccess(client, secrets.get(CKey.saas_account_id))
host=secrets.get(CKey.saas_url),
pat=secrets.get(CKey.saas_token)))
api_access = OpenApiAccess(
client=client,
account_id=secrets.get(CKey.saas_account_id))
stack.enter_context(api_access.allowed_ip())
db = stack.enter_context(api_access.database(
secrets.get(CKey.saas_database_name)))
name=secrets.get(CKey.saas_database_name),
idle_time=timedelta(hours=12)))
api_access.wait_until_running(db.id)
yield store_path, store_password

Expand Down

0 comments on commit 9ccdfc2

Please sign in to comment.