-
Notifications
You must be signed in to change notification settings - Fork 7
Expand file tree
/
Copy pathissue_example_test.go
More file actions
34 lines (31 loc) · 1004 Bytes
/
issue_example_test.go
File metadata and controls
34 lines (31 loc) · 1004 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
package cypher
import "testing"
func TestGh48(t *testing.T) {
n := ANode("Label").NamedByString("n")
statement, err := Match(n).
SetWithNamed(n, MapOf("a", StringLiteralCreate("bar"), "b", StringLiteralCreate("baz"))).
ReturningByNamed(n).
Build()
if err != nil {
t.Errorf("error When build query: %s", err)
}
query, _ := NewRenderer().Render(statement)
if query != "MATCH (n:`Label`) SET n = {`a`: 'bar', `b`: 'baz'} RETURN n" {
t.Errorf("Query is not MatchPhrase: %s", query)
}
}
//func TestGh51(t *testing.T) {
// n := CypherAnyNode1("n")
// foobarProp := proper
// statement, err := Match(n).
// SetWithNamed(n, MapOf("a", StringLiteralCreate("bar"), "b", StringLiteralCreate("baz"))).
// ReturningByNamed(n).
// Build()
// if err != nil {
// t.Errorf("error When build query: %s", err)
// }
// query := NewRenderer().Render(statement)
// if query != "MATCH (n:`Label`) SET n = {`a`: 'bar', `b`: 'baz'} RETURN n" {
// t.Errorf("Query is not MatchPhrase: %s", query)
// }
//}