提交 9efb009d 编写于 作者: M Mark Needham

oops, same test twice!

上级 8a5f9352
......@@ -632,25 +632,7 @@ public class ExportCypherTest {
});
}
@Test
public void shouldQuotePropertyNameStartingWithDollarCharacter() {
db.executeTransactionally("CREATE (n:Bar:Baz{name: 'A', `$lock`: true})");
String query = "MATCH (n:Baz) RETURN n";
final String expected = "UNWIND [{name:\"A\", properties:{`$lock`:true}}] AS row\n" +
"CREATE (n:Bar{name: row.name}) SET n += row.properties SET n:Baz";
TestUtil.testCall(db, "CALL apoc.export.cypher.query($query, $file, $config)",
map("file", null, "query", query, "config", map("format", "plain", "stream", true)), (r) -> {
final String cypherStatements = (String) r.get("cypherStatements");
String unwind = Stream.of(cypherStatements.split(";"))
.map(String::trim)
.filter(s -> s.startsWith("UNWIND"))
.findFirst()
.orElse(null);
assertEquals(expected, unwind);
});
}
@Test
public void shouldQuotePropertyNameStartingWithDollarCharacter() {
db.executeTransactionally("CREATE (n:Bar:Baz{name: 'A', `$lock`: true})");
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册