Skip to content

Commit 555886a

Browse files
emirkmo=
authored andcommitted
Add failing replicated persist docs test
failure requires `test_replica` cluster to be used.
1 parent 368a8d6 commit 555886a

File tree

1 file changed

+24
-1
lines changed

1 file changed

+24
-1
lines changed

tests/integration/adapter/clickhouse/test_clickhouse_comments.py

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,21 @@
1818
1919
"""
2020

21+
ref_models__replicated_table_comment_sql = """
22+
{{
23+
config(
24+
materialized = "table",
25+
persist_docs = {"relation": true, "columns": true},
26+
engine="ReplicatedMergeTree('/clickhouse/tables/{uuid}/one-shard', '{replica}' )"
27+
)
28+
}}
29+
30+
select
31+
'foo' as first_name,
32+
'bar' as second_name
33+
34+
"""
35+
2136
ref_models__view_comment_sql = """
2237
{{
2338
config(
@@ -43,6 +58,13 @@
4358
description: "XXX first description"
4459
- name: second_name
4560
description: "XXX second description"
61+
- name: replicated_table_comment
62+
description: "YYY table"
63+
columns:
64+
- name: first_name
65+
description: "XXX first description"
66+
- name: second_name
67+
description: "XXX second description"
4668
- name: view_comment
4769
description: "YYY view"
4870
columns:
@@ -59,12 +81,13 @@ def models(self):
5981
return {
6082
"schema.yml": ref_models__schema_yml,
6183
"table_comment.sql": ref_models__table_comment_sql,
84+
"replicated_table_comment.sql": ref_models__replicated_table_comment_sql,
6285
"view_comment.sql": ref_models__view_comment_sql,
6386
}
6487

6588
@pytest.mark.parametrize(
6689
'model_name',
67-
['table_comment', 'view_comment'],
90+
["table_comment", "replicated_table_comment", "view_comment"],
6891
)
6992
def test_comment(self, project, model_name):
7093
if os.environ.get('DBT_CH_TEST_CLOUD', '').lower() in ('1', 'true', 'yes'):

0 commit comments

Comments
 (0)