MCPcopy
hub / github.com/dgraph-io/dgraph / TestIncompleteBlockErr

Function TestIncompleteBlockErr

dql/upsert_test.go:115–130  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

113}
114
115func TestIncompleteBlockErr(t *testing.T) {
116 query := `
117upsert {
118 mutation {
119 set {
120 "_:user1" <age> "45" .
121 }
122 }
123
124 query {
125 me(func: eq(age, "{
126`
127 _, err := ParseDQL(query)
128 require.Error(t, err)
129 require.Contains(t, err.Error(), "Unexpected end of input")
130}
131
132func TestMissingQueryErr(t *testing.T) {
133 query := `

Callers

nothing calls this directly

Calls 2

ParseDQLFunction · 0.85
ErrorMethod · 0.45

Tested by

no test coverage detected