(t *testing.T, hc *dgraphapi.HTTPClient, project ProjectInput)
| 79 | } |
| 80 | |
| 81 | func addProject(t *testing.T, hc *dgraphapi.HTTPClient, project ProjectInput) { |
| 82 | query := ` |
| 83 | mutation addProject($project: AddProjectInput!) { |
| 84 | addProject(input: [$project]) { |
| 85 | project { |
| 86 | title |
| 87 | title_v |
| 88 | } |
| 89 | } |
| 90 | }` |
| 91 | |
| 92 | params := dgraphapi.GraphQLParams{ |
| 93 | Query: query, |
| 94 | Variables: map[string]interface{}{"project": project}, |
| 95 | } |
| 96 | |
| 97 | _, err := hc.RunGraphqlQuery(params, false) |
| 98 | require.NoError(t, err) |
| 99 | } |
| 100 | |
| 101 | func queryProjectUsingTitle(t *testing.T, hc *dgraphapi.HTTPClient, title string) ProjectInput { |
| 102 | query := ` query QueryProject($title: String!) { |
no test coverage detected