Skip to content

Commit

Permalink
Add DbtDatabaseError to test_missing_column_pre_hook
Browse files Browse the repository at this point in the history
  • Loading branch information
bobbyiliev committed Dec 18, 2024
1 parent 508e883 commit 2923e09
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion misc/dbt-materialize/tests/adapter/test_run_hooks.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
BasePrePostRunHooks,
)
from dbt.tests.util import run_dbt
from dbt_common.exceptions import DbtDatabaseError
from fixtures import run_hook, test_run_operation


Expand Down Expand Up @@ -58,6 +59,7 @@ def check_hooks(self, state, project, host):

class TestAfterRunHooksMaterialize(BaseAfterRunHooks):
def test_missing_column_pre_hook(self, project):
run_dbt(["run"], expect_pass=False)
with pytest.raises(DbtDatabaseError):
run_dbt(["run"], expect_pass=False)

pass

0 comments on commit 2923e09

Please sign in to comment.