Fix last broken test

This commit is contained in:
Ivan Lezhankin 2019-06-14 19:53:16 +03:00
parent 10c7bcf98f
commit a09f715265
2 changed files with 6 additions and 6 deletions

View File

@ -1,3 +1,5 @@
CREATE DATABASE IF NOT EXISTS test_00857;
USE test_00857;
DROP TABLE IF EXISTS local_table; DROP TABLE IF EXISTS local_table;
DROP TABLE IF EXISTS other_table; DROP TABLE IF EXISTS other_table;
@ -22,9 +24,8 @@ INSERT INTO local_table VALUES(2, 'Two', now(), 200);
INSERT INTO other_table VALUES(100, 'One Hundred', now(), 1000); INSERT INTO other_table VALUES(100, 'One Hundred', now(), 1000);
INSERT INTO other_table VALUES(200, 'Two Hundred', now(), 2000); INSERT INTO other_table VALUES(200, 'Two Hundred', now(), 2000);
-- FIXME: other_table -> other_table in first query breaks test (external tables cache error)
select t2.name from remote('127.0.0.2', currentDatabase(), 'local_table') as t1 select t2.name from remote('127.0.0.2', currentDatabase(), 'local_table') as t1
left join other_table as t2 left join test_00857.other_table as t2 -- FIXME: doesn't work properly on remote without explicit database prefix
on t1.oth_id = t2.id on t1.oth_id = t2.id
order by t2.name; order by t2.name;
@ -55,3 +56,4 @@ order by other_table.name;
DROP TABLE local_table; DROP TABLE local_table;
DROP TABLE other_table; DROP TABLE other_table;
DROP DATABASE test_00857;

View File

@ -37,10 +37,8 @@ def sql_query(request):
@pytest.fixture @pytest.fixture
def standalone_server(bin_prefix): def standalone_server(bin_prefix, tmp_path):
tmp_dir = tempfile.mkdtemp(prefix='clickhouse.test..') server = ServerThread(bin_prefix, str(tmp_path))
server = ServerThread(bin_prefix, tmp_dir)
server.start() server.start()
wait_result = server.wait() wait_result = server.wait()