ClickHouse/tests/queries/0_stateless/02113_hdfs_assert.sh

11 lines
390 B
Bash
Raw Normal View History

2021-11-03 09:53:33 +00:00
#!/usr/bin/env bash
# Tags: no-fasttest, use-hdfs
2021-11-03 09:53:33 +00:00
CURDIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)
# shellcheck source=../shell_config.sh
. "$CURDIR"/../shell_config.sh
TCP_PORT=$($CLICKHOUSE_CLIENT -q "SELECT tcpPort()")
2023-11-09 11:57:42 +00:00
$CLICKHOUSE_CLIENT -q "SELECT * FROM hdfs('hdfs://localhost:$TCP_PORT/data.csv', 'CSV', 'x UInt32')" 2>&1 | grep -F -q "HDFS_ERROR" && echo 'OK' || echo 'FAIL';