Skip to content

Commit

Permalink
Add store_failures_as config for generic tests
Browse files Browse the repository at this point in the history
  • Loading branch information
dbeatty10 committed Sep 30, 2023
1 parent c214595 commit 0baf090
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions core/dbt/parser/generic_test_builders.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@ class TestBuilder(Generic[Testable]):
"error_if",
"fail_calc",
"store_failures",
"store_failures_as",
"meta",
"database",
"schema",
Expand Down Expand Up @@ -242,6 +243,10 @@ def severity(self) -> Optional[str]:
def store_failures(self) -> Optional[bool]:
return self.config.get("store_failures")

@property
def store_failures_as(self) -> Optional[bool]:
return self.config.get("store_failures_as")

@property
def where(self) -> Optional[str]:
return self.config.get("where")
Expand Down Expand Up @@ -294,6 +299,8 @@ def get_static_config(self):
config["fail_calc"] = self.fail_calc
if self.store_failures is not None:
config["store_failures"] = self.store_failures
if self.store_failures_as is not None:
config["store_failures_as"] = self.store_failures_as
if self.meta is not None:
config["meta"] = self.meta
if self.database is not None:
Expand Down

0 comments on commit 0baf090

Please sign in to comment.