mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-24 16:42:05 +00:00
Updated tests
This commit is contained in:
parent
39105fc233
commit
289b9fda99
@ -2,7 +2,7 @@
|
||||
1 Hello, world 2005-05-05 05:05:05
|
||||
2 test 2005-05-25 15:00:00
|
||||
2 test 2005-05-25 15:00:00
|
||||
Code: 36.
|
||||
Code: 456.
|
||||
abc
|
||||
abc
|
||||
Hello, world
|
||||
|
@ -3,4 +3,4 @@
|
||||
[10,10,10]
|
||||
[[10],[10],[10]]
|
||||
[10,10,10] [[10],[10],[10]] (10,'Test') (10,('dt',10)) 2015-02-15
|
||||
OK
|
||||
Code: 457.
|
||||
|
@ -3,9 +3,7 @@
|
||||
CURDIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)
|
||||
. $CURDIR/../shell_config.sh
|
||||
|
||||
EXCEPTION_TEXT="Code: 456."
|
||||
EXCEPTION_SUCCESS_TEXT="OK"
|
||||
EXCEPTION_FAIL_TEXT="FAIL"
|
||||
EXCEPTION_TEXT="Code: 457."
|
||||
|
||||
$CLICKHOUSE_CLIENT -q "DROP TABLE IF EXISTS ps";
|
||||
$CLICKHOUSE_CLIENT -q "CREATE TABLE ps (
|
||||
@ -37,7 +35,6 @@ $CLICKHOUSE_CLIENT --max_threads=1 --param_nd="2015-02-15" \
|
||||
# Must throw an exception to avoid SQL injection
|
||||
$CLICKHOUSE_CLIENT --max_threads=1 --param_injection="[1] OR 1" \
|
||||
-q "SELECT * FROM ps WHERE a = {injection:Array(UInt32)}" 2>&1 \
|
||||
| grep -q "$EXCEPTION_TEXT" && echo "$EXCEPTION_SUCCESS_TEXT" \
|
||||
|| echo "$EXCEPTION_FAIL_TEXT";
|
||||
| grep -o "$EXCEPTION_TEXT"
|
||||
|
||||
$CLICKHOUSE_CLIENT -q "DROP TABLE ps";
|
||||
|
Loading…
Reference in New Issue
Block a user