@@ -8,36 +8,36 @@ class MutationTest extends TestCase
88{
99 public function testMutation ()
1010 {
11- $ string = 'mutation{testing(id:5,test:{test2:5}){test3{test4}}} ' ;
11+ $ string = 'mutation{testing(id:5,nullarg:null, test:{test2:5}){test3{test4}}} ' ;
1212
1313 $ mutation = new Mutation ('testing ' );
1414 $ mutation
1515 ->addSelect (['test3 ' => ['test4 ' ]])
16- ->addArguments (['id ' => 5 , 'test ' => ['test2 ' => 5 ]]);
16+ ->addArguments (['id ' => 5 , 'nullarg ' => null , ' test ' => ['test2 ' => 5 ]]);
1717
1818 $ this ->assertSame ($ string , $ mutation ->getPreparedQuery ());
1919 }
2020
2121 public function testMutation2 ()
2222 {
23- $ string = 'mutation{testing(id:{user_id:5,user_type:"account"},test:{test2:5}){test3{test4}}} ' ;
23+ $ string = 'mutation{testing(id:{user_id:5,nullarg:null, user_type:"account"},test:{test2:5}){test3{test4}}} ' ;
2424
2525 $ mutation = new Mutation ('testing ' );
2626 $ mutation
2727 ->addSelect (['test3 ' => ['test4 ' ]])
28- ->addArguments (['id ' => ['user_id ' => 5 , 'user_type ' => 'account ' ], 'test ' => ['test2 ' => 5 ]]);
28+ ->addArguments (['id ' => ['user_id ' => 5 , 'nullarg ' => null , ' user_type ' => 'account ' ], 'test ' => ['test2 ' => 5 ]]);
2929
3030 $ this ->assertSame ($ string , $ mutation ->getPreparedQuery ());
3131 }
3232
3333 public function testMutation3 ()
3434 {
35- $ string = 'mutation{testing(id:{user_id:"5",user_type:ACCOUNT},test:{test2:5}){test3{test4}}} ' ;
35+ $ string = 'mutation{testing(id:{user_id:"5",nullarg:null, user_type:ACCOUNT},test:{test2:5}){test3{test4}}} ' ;
3636
3737 $ mutation = new Mutation ('testing ' );
3838 $ mutation
3939 ->addSelect (['test3 ' => ['test4 ' ]])
40- ->addArguments (['id ' => ['user_id ' => '5 ' , 'user_type ' => new Enum ('ACCOUNT ' )], 'test ' => ['test2 ' => 5 ]]);
40+ ->addArguments (['id ' => ['user_id ' => '5 ' , 'nullarg ' => null , ' user_type ' => new Enum ('ACCOUNT ' )], 'test ' => ['test2 ' => 5 ]]);
4141
4242 $ this ->assertSame ($ string , $ mutation ->getPreparedQuery ());
4343 }
0 commit comments