This commit is contained in:
Ivan Lezhankin 2019-09-11 15:29:26 +03:00
parent 8d5a08743a
commit 622ab139ee

View File

@ -248,6 +248,21 @@ def test_kafka_tsv_with_delimiter(kafka_cluster):
kafka_check_result(result, True) kafka_check_result(result, True)
@pytest.mark.timeout(180)
def test_kafka_select_empty(kafka_cluster):
instance.query('''
CREATE TABLE test.kafka (key UInt64)
ENGINE = Kafka
SETTINGS kafka_broker_list = 'kafka1:19092',
kafka_topic_list = 'empty',
kafka_group_name = 'empty',
kafka_format = 'TSV',
kafka_row_delimiter = '\\n';
''')
assert int(instance.query('SELECT count() FROM test.kafka')) == 0
@pytest.mark.timeout(180) @pytest.mark.timeout(180)
def test_kafka_json_without_delimiter(kafka_cluster): def test_kafka_json_without_delimiter(kafka_cluster):
instance.query(''' instance.query('''