Added a test

This commit is contained in:
Alexey Milovidov 2020-10-16 03:07:56 +03:00
parent 4bf32cb15b
commit 2efd740dc7
2 changed files with 26 additions and 0 deletions

View File

@ -0,0 +1 @@
Ok

View File

@ -0,0 +1,25 @@
#!/usr/bin/env bash
CURDIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)
. "$CURDIR"/../shell_config.sh
# Create a huge amount of tables, so Suggest will take a time to load
seq 1 1000 | sed -r -e 's/(.+)/CREATE TABLE IF NOT EXISTS test\1 (x UInt8) ENGINE = Memory;/' | ${CLICKHOUSE_CLIENT} -n
function stress()
{
while true; do
./"$CURDIR"/01526_client_start_and_exit.expect
done
}
export -f stress
for _ in {1..10}; do
timeout 3 bash -c stress &
done
wait
echo 'Ok'
seq 1 1000 | sed -r -e 's/(.+)/DROP TABLE test\1;/' | ${CLICKHOUSE_CLIENT} -n