Skip to content

Commit 78a2139

Browse files
committed
restore timeouts, mark as no-fasttests
1 parent 1e5bc5b commit 78a2139

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

tests/queries/0_stateless/03172_error_log_table_not_empty.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
#!/usr/bin/env bash
2+
# Tags: no-fasttest
3+
# Tag no-fasttest: this test relies on the timeouts, it always takes no less that 4 seconds to run
24

35
CURDIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)
46
# shellcheck source=../shell_config.sh
@@ -12,11 +14,12 @@ errors_111=$($CLICKHOUSE_CLIENT -q "SELECT sum(value) FROM system.error_log WHER
1214
errors_222=$($CLICKHOUSE_CLIENT -q "SELECT sum(value) FROM system.error_log WHERE code = 222")
1315
errors_333=$($CLICKHOUSE_CLIENT -q "SELECT sum(value) FROM system.error_log WHERE code = 333")
1416

15-
# Throw three random errors: 111, 222 and 333 and call flush logs to ensure system.error_log is flushed
17+
# Throw three random errors: 111, 222 and 333 and wait for more than collect_interval_milliseconds to ensure system.error_log is flushed
1618
$CLICKHOUSE_CLIENT -mn -q "
1719
SELECT throwIf(true, 'error_log', toInt16(111)) SETTINGS allow_custom_error_code_in_throwif=1; -- { serverError 111 }
1820
SELECT throwIf(true, 'error_log', toInt16(222)) SETTINGS allow_custom_error_code_in_throwif=1; -- { serverError 222 }
1921
SELECT throwIf(true, 'error_log', toInt16(333)) SETTINGS allow_custom_error_code_in_throwif=1; -- { serverError 333 }
22+
SELECT sleep(2) format NULL;
2023
SYSTEM FLUSH LOGS;
2124
"
2225

@@ -32,6 +35,7 @@ $CLICKHOUSE_CLIENT -mn -q "
3235
SELECT throwIf(true, 'error_log', toInt16(111)) SETTINGS allow_custom_error_code_in_throwif=1; -- { serverError 111 }
3336
SELECT throwIf(true, 'error_log', toInt16(222)) SETTINGS allow_custom_error_code_in_throwif=1; -- { serverError 222 }
3437
SELECT throwIf(true, 'error_log', toInt16(333)) SETTINGS allow_custom_error_code_in_throwif=1; -- { serverError 333 }
38+
SELECT sleep(2) format NULL;
3539
SYSTEM FLUSH LOGS;
3640
"
3741

0 commit comments

Comments
 (0)