From 1bf1bda613af28f373507b0dac1e555951f5f7d0 Mon Sep 17 00:00:00 2001 From: colin-rogers-dbt <111200756+colin-rogers-dbt@users.noreply.github.com> Date: Sun, 21 Jan 2024 09:42:51 -0800 Subject: [PATCH] add TableLastModifiedMetadata capability enum to impl and specify timeout (#1075) --- dbt/adapters/bigquery/impl.py | 5 ++++- dev-requirements.txt | 1 + tox.ini | 4 ++-- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/dbt/adapters/bigquery/impl.py b/dbt/adapters/bigquery/impl.py index 2bc86969e..f2e8b11a0 100644 --- a/dbt/adapters/bigquery/impl.py +++ b/dbt/adapters/bigquery/impl.py @@ -121,7 +121,10 @@ class BigQueryAdapter(BaseAdapter): } _capabilities = CapabilityDict( - {Capability.SchemaMetadataByRelations: CapabilitySupport(support=Support.Full)} + { + Capability.SchemaMetadataByRelations: CapabilitySupport(support=Support.Full), + Capability.TableLastModifiedMetadata: CapabilitySupport(support=Support.Full), + } ) def __init__(self, config) -> None: diff --git a/dev-requirements.txt b/dev-requirements.txt index a20a37545..0362f627f 100644 --- a/dev-requirements.txt +++ b/dev-requirements.txt @@ -22,6 +22,7 @@ pytest-csv~=3.0 pytest-dotenv~=0.5.2 pytest-logbook~=1.2 pytest-xdist~=3.3 +pytest-timeout~=2.0 pytz~=2023.3 tox~=4.11 types-pytz~=2023.3 diff --git a/tox.ini b/tox.ini index 1d5413dcf..b5819586c 100644 --- a/tox.ini +++ b/tox.ini @@ -28,7 +28,7 @@ passenv = DD_ENV DD_SERVICE commands = - bigquery: {envpython} -m pytest {posargs} -vv tests/functional -k "not TestPython" --profile service_account + bigquery: {envpython} -m pytest {posargs} --timeout 600 -vv tests/functional -k "not TestPython" --profile service_account deps = -rdev-requirements.txt -e. @@ -48,7 +48,7 @@ passenv = DD_ENV DD_SERVICE commands = - {envpython} -m pytest {posargs} -vv tests/functional -k "TestPython" --profile service_account + {envpython} -m pytest {posargs} --timeout 600 -vv tests/functional -k "TestPython" --profile service_account deps = -rdev-requirements.txt -e.