Skip to content

Commit 455cef2

Browse files
Update playground tests with playground configuration
Format tests with gofmt (cherry picked from commit 3afa9bf)
1 parent 94849fc commit 455cef2

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

graphcoolPlayground_test.go

+5-3
Original file line numberDiff line numberDiff line change
@@ -62,9 +62,11 @@ func TestRenderPlayground(t *testing.T) {
6262
req.Header.Set("Accept", tc.accept)
6363

6464
h := handler.New(&handler.Config{
65-
Schema: &testutil.StarWarsSchema,
66-
GraphiQL: false,
67-
Playground: tc.playgroundEnabled,
65+
Schema: &testutil.StarWarsSchema,
66+
GraphiQL: false,
67+
Playground: &handler.PlaygroundConfig{
68+
Enabled: tc.playgroundEnabled,
69+
},
6870
})
6971

7072
rr := httptest.NewRecorder()

handler_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ func TestHandler_BasicQuery_WithFormatErrorFn(t *testing.T) {
245245
customFormattedError := gqlerrors.FormattedError{
246246
Message: resolverError.Error(),
247247
Locations: []location.SourceLocation{
248-
location.SourceLocation{
248+
{
249249
Line: 1,
250250
Column: 2,
251251
},

0 commit comments

Comments
 (0)