From e5028d91ea8958f45f42249c93b06e8165d40a16 Mon Sep 17 00:00:00 2001 From: Matej Ferencevic Date: Tue, 28 Aug 2018 22:58:58 +0200 Subject: [PATCH] Improve Kafka test Reviewers: msantl, mtomic Reviewed By: mtomic Subscribers: pullbot Differential Revision: https://phabricator.memgraph.io/D1574 --- tests/integration/kafka/transform.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/integration/kafka/transform.py b/tests/integration/kafka/transform.py index 1fd87ca9b..d0740f360 100644 --- a/tests/integration/kafka/transform.py +++ b/tests/integration/kafka/transform.py @@ -9,7 +9,7 @@ def stream(batch): for item in batch: message = item.decode("utf-8").strip().split() if len(message) == 1: - ret.append(("CREATE (:node {num: $num})", {"num": message[0]})) + ret.append(("MERGE (:node {num: $num})", {"num": message[0]})) elif len(message) == 2: - ret.append(("MATCH (n:node {num: $num1}), (m:node {num: $num2}) CREATE (n)-[:et]->(m)", {"num1": message[0], "num2": message[1]})) + ret.append(("MATCH (n:node {num: $num1}), (m:node {num: $num2}) MERGE (n)-[:et]->(m)", {"num1": message[0], "num2": message[1]})) return ret