Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
2dot5
ClickHouse
提交
da33310f
C
ClickHouse
项目概览
2dot5
/
ClickHouse
通知
3
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
C
ClickHouse
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
da33310f
编写于
2月 24, 2019
作者:
A
alesapin
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Add multiple rows to test, fix bug
上级
22a54bbd
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
32 addition
and
14 deletion
+32
-14
dbms/tests/integration/test_external_dictionaries/external_sources.py
...ntegration/test_external_dictionaries/external_sources.py
+2
-2
dbms/tests/integration/test_external_dictionaries/test.py
dbms/tests/integration/test_external_dictionaries/test.py
+30
-12
未找到文件。
dbms/tests/integration/test_external_dictionaries/external_sources.py
浏览文件 @
da33310f
...
...
@@ -119,7 +119,7 @@ class SourceMySQL(ExternalSource):
query
=
'insert into test.{} ({}) values {}'
.
format
(
table_name
,
','
.
join
(
self
.
ordered_names
),
''
.
join
(
values_strs
))
'
,
'
.
join
(
values_strs
))
self
.
execute_mysql_query
(
query
)
...
...
@@ -208,7 +208,7 @@ class SourceClickHouse(ExternalSource):
query
=
'INSERT INTO test.{} ({}) values {}'
.
format
(
table_name
,
','
.
join
(
self
.
ordered_names
),
''
.
join
(
values_strs
))
'
,
'
.
join
(
values_strs
))
self
.
node
.
query
(
query
)
...
...
dbms/tests/integration/test_external_dictionaries/test.py
浏览文件 @
da33310f
...
...
@@ -141,9 +141,14 @@ def started_cluster():
def
test_simple_dictionaries
(
started_cluster
):
fields
=
FIELDS
[
"simple"
]
data
=
[
Row
(
fields
,
[
1
,
22
,
333
,
4444
,
55555
,
-
6
,
-
77
,
-
888
,
-
999
,
'550e8400-e29b-41d4-a716-446655440003'
,
'1973-06-28'
,
'1985-02-28 23:43:25'
,
'hello'
,
22.543
,
3332154213.4
]),
Row
(
fields
,
[
1
,
22
,
333
,
4444
,
55555
,
-
6
,
-
77
,
-
888
,
-
999
,
'550e8400-e29b-41d4-a716-446655440003'
,
'1973-06-28'
,
'1985-02-28 23:43:25'
,
'hello'
,
22.543
,
3332154213.4
]),
Row
(
fields
,
[
2
,
3
,
4
,
5
,
6
,
-
7
,
-
8
,
-
9
,
-
10
,
'550e8400-e29b-41d4-a716-446655440002'
,
'1978-06-28'
,
'1986-02-28 23:42:25'
,
'hello'
,
21.543
,
3222154213.4
]),
]
simple_dicts
=
[
d
for
d
in
DICTIONARIES
if
d
.
structure
.
layout
.
layout_type
==
"simple"
]
...
...
@@ -173,10 +178,16 @@ def test_simple_dictionaries(started_cluster):
def
test_complex_dictionaries
(
started_cluster
):
fields
=
FIELDS
[
"complex"
]
data
=
[
Row
(
fields
,
[
1
,
'world'
,
22
,
333
,
4444
,
55555
,
-
6
,
-
77
,
-
888
,
-
999
,
'550e8400-e29b-41d4-a716-446655440003'
,
'1973-06-28'
,
'1985-02-28 23:43:25'
,
'hello'
,
22.543
,
3332154213.4
]),
Row
(
fields
,
[
1
,
'world'
,
22
,
333
,
4444
,
55555
,
-
6
,
-
77
,
-
888
,
-
999
,
'550e8400-e29b-41d4-a716-446655440003'
,
'1973-06-28'
,
'1985-02-28 23:43:25'
,
'hello'
,
22.543
,
3332154213.4
]),
Row
(
fields
,
[
2
,
'qwerty2'
,
52
,
2345
,
6544
,
9191991
,
-
2
,
-
717
,
-
81818
,
-
92929
,
'550e8400-e29b-41d4-a716-446655440007'
,
'1975-09-28'
,
'2000-02-28 23:33:24'
,
'my'
,
255.543
,
333222154213.4
]),
]
complex_dicts
=
[
d
for
d
in
DICTIONARIES
if
d
.
structure
.
layout
.
layout_type
==
"complex"
]
...
...
@@ -206,11 +217,18 @@ def test_complex_dictionaries(started_cluster):
def
test_ranged_dictionaries
(
started_cluster
):
fields
=
FIELDS
[
"ranged"
]
data
=
[
Row
(
fields
,
[
1
,
'2019-02-10'
,
'2019-02-01'
,
'2019-02-28'
,
22
,
333
,
4444
,
55555
,
-
6
,
-
77
,
-
888
,
-
999
,
'550e8400-e29b-41d4-a716-446655440003'
,
'1973-06-28'
,
'1985-02-28 23:43:25'
,
'hello'
,
22.543
,
3332154213.4
]),
Row
(
fields
,
[
1
,
'2019-02-10'
,
'2019-02-01'
,
'2019-02-28'
,
22
,
333
,
4444
,
55555
,
-
6
,
-
77
,
-
888
,
-
999
,
'550e8400-e29b-41d4-a716-446655440003'
,
'1973-06-28'
,
'1985-02-28 23:43:25'
,
'hello'
,
22.543
,
3332154213.4
]),
Row
(
fields
,
[
1
,
'2019-04-10'
,
'2019-04-01'
,
'2019-04-28'
,
555
,
32323
,
414144
,
5255515
,
-
65
,
-
747
,
-
8388
,
-
9099
,
'550e8400-e29b-41d4-a716-446655440004'
,
'1973-06-29'
,
'2002-02-28 23:23:25'
,
'!!!!'
,
32.543
,
33321545513.4
]),
]
ranged_dicts
=
[
d
for
d
in
DICTIONARIES
if
d
.
structure
.
layout
.
layout_type
==
"ranged"
]
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录