mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-18 21:51:57 +00:00
test added
This commit is contained in:
parent
1680be19ca
commit
33b0b1828a
1
tests/queries/0_stateless/02377_quota_key.reference
Normal file
1
tests/queries/0_stateless/02377_quota_key.reference
Normal file
@ -0,0 +1 @@
|
|||||||
|
1
|
16
tests/queries/0_stateless/02377_quota_key.sh
Executable file
16
tests/queries/0_stateless/02377_quota_key.sh
Executable file
@ -0,0 +1,16 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
# Tags: no-parallel
|
||||||
|
|
||||||
|
CURDIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)
|
||||||
|
# shellcheck source=../shell_config.sh
|
||||||
|
. "$CURDIR"/../shell_config.sh
|
||||||
|
|
||||||
|
${CLICKHOUSE_CLIENT} -q "DROP USER IF EXISTS u_02377"
|
||||||
|
${CLICKHOUSE_CLIENT} -q "drop quota if exists q_02377"
|
||||||
|
${CLICKHOUSE_CLIENT} -q "CREATE USER u_02377 IDENTIFIED WITH plaintext_password BY 'password';"
|
||||||
|
${CLICKHOUSE_CLIENT} -q "CREATE QUOTA q_02377 KEYED BY client_key FOR INTERVAL 1 month MAX queries = 100 TO u_02377;"
|
||||||
|
|
||||||
|
${CLICKHOUSE_CLIENT} --user=u_02377 --password=password --quota_key=q_02377 --query="select 1"
|
||||||
|
|
||||||
|
${CLICKHOUSE_CLIENT} -q "DROP USER IF EXISTS u_02377"
|
||||||
|
${CLICKHOUSE_CLIENT} -q "drop quota if exists q_02377"
|
Loading…
Reference in New Issue
Block a user