Skip to content

Commit

Permalink
Test for remote_servers override
Browse files Browse the repository at this point in the history
  • Loading branch information
alex-zaitsev committed Aug 19, 2020
1 parent c6812b3 commit 730166a
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 1 deletion.
5 changes: 5 additions & 0 deletions tests/configs/test-016-settings-2.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,11 @@ spec:
</test_norestart>
</users>
</yandex>
config.d/remote_servers.xml:
<yandex>
<remote_servers replace="1">
</remote_servers>
</yandex>
dict_one.dict: |
<yandex>
<dictionary>
Expand Down
5 changes: 5 additions & 0 deletions tests/configs/test-016-settings.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,11 @@ spec:
</test_usersd>
</users>
</yandex>
config.d/remote_servers.xml:
<yandex>
<remote_servers replace="1">
</remote_servers>
</yandex>
dict_one.dict: |
<yandex>
<dictionary>
Expand Down
6 changes: 5 additions & 1 deletion tests/test_operator.py
Original file line number Diff line number Diff line change
Expand Up @@ -427,7 +427,11 @@ def test_016():

with And("test_usersd user should be available"):
clickhouse_query(chi, query = "select version()", user = "test_usersd")


with And("system.clusters should be empty due to remote_servers override"):
out = clickhouse_query(chi, query = "select count() from system.clusters")
assert out == "0"

with When("Update usersd settings"):
start_time = kube_get_field("pod", f"chi-{chi}-default-0-0-0", ".status.startTime")
create_and_check("configs/test-016-settings-2.yaml", {"do_not_delete": 1})
Expand Down

0 comments on commit 730166a

Please sign in to comment.