Skip to content

Commit

Permalink
fix broken sample tests
Browse files Browse the repository at this point in the history
Improve dosctrings
  • Loading branch information
daniel-sanche authored Jun 7, 2024
2 parents 9398461 + 4b19338 commit 3b87c1c
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 5 deletions.
3 changes: 2 additions & 1 deletion samples/quickstart/main_async_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@
from typing import AsyncGenerator

from google.cloud.bigtable.data import BigtableDataClientAsync, SetCell
import pytest, pytest_asyncio
import pytest
import pytest_asyncio

from main_async import main

Expand Down
1 change: 1 addition & 0 deletions samples/quickstart/requirements-test.txt
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
pytest==7.4.4
pytest-asyncio
2 changes: 1 addition & 1 deletion samples/quickstart/requirements.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
google-cloud-bigtable==2.22.0
google-cloud-bigtable==2.23.0
5 changes: 3 additions & 2 deletions samples/snippets/deletes/deletes_async_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
from typing import AsyncGenerator

from google.cloud._helpers import _microseconds_from_datetime
import pytest, pytest_asyncio
import pytest
import pytest_asyncio

import deletes_snippets_async

Expand Down Expand Up @@ -72,7 +73,7 @@ async def _populate_table(table_id):
timestamp = datetime.datetime(2019, 5, 1)
timestamp_minus_hr = timestamp - datetime.timedelta(hours=1)

async with (BigtableDataClientAsync(project=PROJECT) as client):
async with BigtableDataClientAsync(project=PROJECT) as client:
async with client.get_table(BIGTABLE_INSTANCE, table_id) as table:
async with table.mutations_batcher() as batcher:
await batcher.append(
Expand Down
1 change: 1 addition & 0 deletions samples/snippets/deletes/requirements-test.txt
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
pytest==7.4.4
pytest-asyncio
2 changes: 1 addition & 1 deletion samples/snippets/deletes/requirements.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
google-cloud-bigtable==2.22.0
google-cloud-bigtable==2.23.0

0 comments on commit 3b87c1c

Please sign in to comment.