Skip to content

Commit

Permalink
Test dbt-core#7537 (#437) (#491)
Browse files Browse the repository at this point in the history
(cherry picked from commit df8a9ab)

Co-authored-by: Jeremy Cohen <[email protected]>
  • Loading branch information
github-actions[bot] and jtcohen6 authored Jun 14, 2023
1 parent a24bad1 commit c45f78a
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions tests/functional/adapter/test_constraints.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
BaseIncrementalConstraintsRuntimeDdlEnforcement,
BaseIncrementalConstraintsRollback,
BaseModelConstraintsRuntimeEnforcement,
BaseConstraintQuotedColumn,
)

_expected_sql_redshift = """
Expand Down Expand Up @@ -124,3 +125,25 @@ def expected_sql(self):
)
;
"""


class TestRedshiftConstraintQuotedColumn(BaseConstraintQuotedColumn):
@pytest.fixture(scope="class")
def expected_sql(self):
return """
create table <model_identifier> (
id integer not null,
"from" text not null,
date_day text
) ;
insert into <model_identifier>
(
select id, "from", date_day
from (
select
'blue' as "from",
1 as id,
'2019-01-01' as date_day
) as model_subq
);
"""

0 comments on commit c45f78a

Please sign in to comment.