github.com/maeglindeveloper/gqlgen@v0.13.1-0.20210413081235-57808b12a0a0/graphql/handler/extension/introspection_test.go (about) 1 package extension 2 3 import ( 4 "context" 5 "testing" 6 7 "github.com/99designs/gqlgen/graphql" 8 "github.com/stretchr/testify/require" 9 ) 10 11 func TestIntrospection(t *testing.T) { 12 rc := &graphql.OperationContext{ 13 DisableIntrospection: true, 14 } 15 require.Nil(t, Introspection{}.MutateOperationContext(context.Background(), rc)) 16 require.Equal(t, false, rc.DisableIntrospection) 17 }