From 1769b6a1bc84b867487cff17849af40bba5c875a Mon Sep 17 00:00:00 2001 From: liningrui Date: Wed, 27 Nov 2019 14:04:19 +0800 Subject: [PATCH] rebase hdfs conf Change-Id: I84120150901a5847200ef3b22295636e9175829b --- .../loader/test/functional/FileLoadTest.java | 4 ++-- .../customized_timezone_gmt0/struct_hdfs.json | 22 +++++++++++++++++++ .../default_timezone_gmt8/struct_hdfs.json | 21 ++++++++++++++++++ 3 files changed, 45 insertions(+), 2 deletions(-) create mode 100644 src/test/resources/customized_timezone_gmt0/struct_hdfs.json create mode 100644 src/test/resources/default_timezone_gmt8/struct_hdfs.json diff --git a/src/test/java/com/baidu/hugegraph/loader/test/functional/FileLoadTest.java b/src/test/java/com/baidu/hugegraph/loader/test/functional/FileLoadTest.java index de5060e59..1445dcae7 100644 --- a/src/test/java/com/baidu/hugegraph/loader/test/functional/FileLoadTest.java +++ b/src/test/java/com/baidu/hugegraph/loader/test/functional/FileLoadTest.java @@ -1237,7 +1237,7 @@ public void testDefaultTimeZoneGMT8() throws java.text.ParseException { "vadas,2000-01-01 13:00:00,Hongkong"); String[] args = new String[]{ - "-f", configPath("default_timezone_gmt8/struct.json"), + "-f", structPath("default_timezone_gmt8/struct.json"), "-s", configPath("default_timezone_gmt8/schema.groovy"), "-g", GRAPH, "-h", SERVER, @@ -1266,7 +1266,7 @@ public void testCustomizedTimeZoneGMT0() throws java.text.ParseException { "vadas,2000-01-01 13:00:00,Hongkong"); String[] args = new String[]{ - "-f", configPath("customized_timezone_gmt0/struct.json"), + "-f", structPath("customized_timezone_gmt0/struct.json"), "-s", configPath("customized_timezone_gmt0/schema.groovy"), "-g", GRAPH, "-h", SERVER, diff --git a/src/test/resources/customized_timezone_gmt0/struct_hdfs.json b/src/test/resources/customized_timezone_gmt0/struct_hdfs.json new file mode 100644 index 000000000..7fc6396ef --- /dev/null +++ b/src/test/resources/customized_timezone_gmt0/struct_hdfs.json @@ -0,0 +1,22 @@ +{ + "vertices": [ + { + "label": "person", + "input": { + "type": "${source_type}", + "path": "${store_path}/vertex_person_birth_date.csv", + "core_site_path": "src/test/resources/hdfs_with_core_site_path/core-site.xml", + "format": "CSV", + "header": ["name", "birth", "city"], + "charset": "UTF-8", + "date_format": "yyyy-MM-dd HH:mm:ss", + "time_zone": "GMT+0" + }, + "field_mapping": { + "name": "name", + "birth": "birth", + "city": "city" + } + } + ] +} diff --git a/src/test/resources/default_timezone_gmt8/struct_hdfs.json b/src/test/resources/default_timezone_gmt8/struct_hdfs.json new file mode 100644 index 000000000..c9294c2ab --- /dev/null +++ b/src/test/resources/default_timezone_gmt8/struct_hdfs.json @@ -0,0 +1,21 @@ +{ + "vertices": [ + { + "label": "person", + "input": { + "type": "${source_type}", + "path": "${store_path}/vertex_person_birth_date.csv", + "core_site_path": "src/test/resources/hdfs_with_core_site_path/core-site.xml", + "format": "CSV", + "header": ["name", "birth", "city"], + "charset": "UTF-8", + "date_format": "yyyy-MM-dd HH:mm:ss" + }, + "field_mapping": { + "name": "name", + "birth": "birth", + "city": "city" + } + } + ] +}