@@ -10,7 +10,7 @@ import { describe, it } from 'mocha';
1010
1111import { missingFieldArgMessage } from '../../validation/rules/ProvidedNonNullArguments' ;
1212import {
13- graphql ,
13+ graphqlSync ,
1414 GraphQLSchema ,
1515 GraphQLObjectType ,
1616 GraphQLList ,
@@ -22,7 +22,7 @@ import {
2222import { getIntrospectionQuery } from '../../utilities/introspectionQuery' ;
2323
2424describe ( 'Introspection' , ( ) => {
25- it ( 'executes an introspection query' , async ( ) => {
25+ it ( 'executes an introspection query' , ( ) => {
2626 const EmptySchema = new GraphQLSchema ( {
2727 query : new GraphQLObjectType ( {
2828 name : 'QueryRoot' ,
@@ -33,7 +33,7 @@ describe('Introspection', () => {
3333 } ) ;
3434
3535 return expect (
36- await graphql ( EmptySchema , getIntrospectionQuery ( ) ) ,
36+ graphqlSync ( EmptySchema , getIntrospectionQuery ( ) ) ,
3737 ) . to . containSubset ( {
3838 data : {
3939 __schema : {
@@ -815,7 +815,7 @@ describe('Introspection', () => {
815815 } ) ;
816816 } ) ;
817817
818- it ( 'introspects on input object' , async ( ) => {
818+ it ( 'introspects on input object' , ( ) => {
819819 const TestInputObject = new GraphQLInputObjectType ( {
820820 name : 'TestInputObject' ,
821821 fields : {
@@ -870,7 +870,7 @@ describe('Introspection', () => {
870870 }
871871 ` ;
872872
873- return expect ( await graphql ( schema , request ) ) . to . containSubset ( {
873+ return expect ( graphqlSync ( schema , request ) ) . to . containSubset ( {
874874 data : {
875875 __schema : {
876876 types : [
@@ -917,7 +917,7 @@ describe('Introspection', () => {
917917 } ) ;
918918 } ) ;
919919
920- it ( 'supports the __type root field' , async ( ) => {
920+ it ( 'supports the __type root field' , ( ) => {
921921 const TestType = new GraphQLObjectType ( {
922922 name : 'TestType' ,
923923 fields : {
@@ -936,7 +936,7 @@ describe('Introspection', () => {
936936 }
937937 ` ;
938938
939- return expect ( await graphql ( schema , request ) ) . to . deep . equal ( {
939+ return expect ( graphqlSync ( schema , request ) ) . to . deep . equal ( {
940940 data : {
941941 __type : {
942942 name : 'TestType' ,
@@ -945,7 +945,7 @@ describe('Introspection', () => {
945945 } ) ;
946946 } ) ;
947947
948- it ( 'identifies deprecated fields' , async ( ) => {
948+ it ( 'identifies deprecated fields' , ( ) => {
949949 const TestType = new GraphQLObjectType ( {
950950 name : 'TestType' ,
951951 fields : {
@@ -973,7 +973,7 @@ describe('Introspection', () => {
973973 }
974974 ` ;
975975
976- return expect ( await graphql ( schema , request ) ) . to . deep . equal ( {
976+ return expect ( graphqlSync ( schema , request ) ) . to . deep . equal ( {
977977 data : {
978978 __type : {
979979 name : 'TestType' ,
@@ -994,7 +994,7 @@ describe('Introspection', () => {
994994 } ) ;
995995 } ) ;
996996
997- it ( 'respects the includeDeprecated parameter for fields' , async ( ) => {
997+ it ( 'respects the includeDeprecated parameter for fields' , ( ) => {
998998 const TestType = new GraphQLObjectType ( {
999999 name : 'TestType' ,
10001000 fields : {
@@ -1026,7 +1026,7 @@ describe('Introspection', () => {
10261026 }
10271027 ` ;
10281028
1029- return expect ( await graphql ( schema , request ) ) . to . deep . equal ( {
1029+ return expect ( graphqlSync ( schema , request ) ) . to . deep . equal ( {
10301030 data : {
10311031 __type : {
10321032 name : 'TestType' ,
@@ -1053,7 +1053,7 @@ describe('Introspection', () => {
10531053 } ) ;
10541054 } ) ;
10551055
1056- it ( 'identifies deprecated enum values' , async ( ) => {
1056+ it ( 'identifies deprecated enum values' , ( ) => {
10571057 const TestEnum = new GraphQLEnumType ( {
10581058 name : 'TestEnum' ,
10591059 values : {
@@ -1086,7 +1086,7 @@ describe('Introspection', () => {
10861086 }
10871087 ` ;
10881088
1089- return expect ( await graphql ( schema , request ) ) . to . deep . equal ( {
1089+ return expect ( graphqlSync ( schema , request ) ) . to . deep . equal ( {
10901090 data : {
10911091 __type : {
10921092 name : 'TestEnum' ,
@@ -1112,7 +1112,7 @@ describe('Introspection', () => {
11121112 } ) ;
11131113 } ) ;
11141114
1115- it ( 'respects the includeDeprecated parameter for enum values' , async ( ) => {
1115+ it ( 'respects the includeDeprecated parameter for enum values' , ( ) => {
11161116 const TestEnum = new GraphQLEnumType ( {
11171117 name : 'TestEnum' ,
11181118 values : {
@@ -1149,7 +1149,7 @@ describe('Introspection', () => {
11491149 }
11501150 ` ;
11511151
1152- return expect ( await graphql ( schema , request ) ) . to . deep . equal ( {
1152+ return expect ( graphqlSync ( schema , request ) ) . to . deep . equal ( {
11531153 data : {
11541154 __type : {
11551155 name : 'TestEnum' ,
@@ -1185,7 +1185,7 @@ describe('Introspection', () => {
11851185 } ) ;
11861186 } ) ;
11871187
1188- it ( 'fails as expected on the __type root field without an arg' , async ( ) => {
1188+ it ( 'fails as expected on the __type root field without an arg' , ( ) => {
11891189 const TestType = new GraphQLObjectType ( {
11901190 name : 'TestType' ,
11911191 fields : {
@@ -1204,7 +1204,7 @@ describe('Introspection', () => {
12041204 }
12051205 ` ;
12061206
1207- return expect ( await graphql ( schema , request ) ) . to . containSubset ( {
1207+ return expect ( graphqlSync ( schema , request ) ) . to . containSubset ( {
12081208 errors : [
12091209 {
12101210 message : missingFieldArgMessage ( '__type' , 'name' , 'String!' ) ,
@@ -1214,7 +1214,7 @@ describe('Introspection', () => {
12141214 } ) ;
12151215 } ) ;
12161216
1217- it ( 'exposes descriptions on types and fields' , async ( ) => {
1217+ it ( 'exposes descriptions on types and fields' , ( ) => {
12181218 const QueryRoot = new GraphQLObjectType ( {
12191219 name : 'QueryRoot' ,
12201220 fields : {
@@ -1236,7 +1236,7 @@ describe('Introspection', () => {
12361236 }
12371237 ` ;
12381238
1239- return expect ( await graphql ( schema , request ) ) . to . deep . equal ( {
1239+ return expect ( graphqlSync ( schema , request ) ) . to . deep . equal ( {
12401240 data : {
12411241 schemaType : {
12421242 name : '__Schema' ,
@@ -1277,7 +1277,7 @@ describe('Introspection', () => {
12771277 } ) ;
12781278 } ) ;
12791279
1280- it ( 'exposes descriptions on enums' , async ( ) => {
1280+ it ( 'exposes descriptions on enums' , ( ) => {
12811281 const QueryRoot = new GraphQLObjectType ( {
12821282 name : 'QueryRoot' ,
12831283 fields : {
@@ -1299,7 +1299,7 @@ describe('Introspection', () => {
12991299 }
13001300 ` ;
13011301
1302- return expect ( await graphql ( schema , request ) ) . to . deep . equal ( {
1302+ return expect ( graphqlSync ( schema , request ) ) . to . deep . equal ( {
13031303 data : {
13041304 typeKindType : {
13051305 name : '__TypeKind' ,
0 commit comments