@@ -164,19 +164,19 @@ |
||
| 164 | 164 | $this->assertEquals(['data' => ['me' => ['firstName' => 'JOHN']]], $processor->getResponseData()); |
| 165 | 165 | |
| 166 | 166 | $schema->getMutationType() |
| 167 | - ->addField(new Field([ |
|
| 168 | - 'name' => 'increaseCounter', |
|
| 169 | - 'type' => new IntType(), |
|
| 170 | - 'resolve' => function ($value, $args, ResolveInfo $info) { |
|
| 171 | - return $this->_counter += $args['amount']; |
|
| 172 | - }, |
|
| 173 | - 'args' => [ |
|
| 174 | - 'amount' => [ |
|
| 175 | - 'type' => new IntType(), |
|
| 176 | - 'default' => 1 |
|
| 177 | - ] |
|
| 178 | - ] |
|
| 179 | - ]))->addField(new Field([ |
|
| 167 | + ->addField(new Field([ |
|
| 168 | + 'name' => 'increaseCounter', |
|
| 169 | + 'type' => new IntType(), |
|
| 170 | + 'resolve' => function ($value, $args, ResolveInfo $info) { |
|
| 171 | + return $this->_counter += $args['amount']; |
|
| 172 | + }, |
|
| 173 | + 'args' => [ |
|
| 174 | + 'amount' => [ |
|
| 175 | + 'type' => new IntType(), |
|
| 176 | + 'default' => 1 |
|
| 177 | + ] |
|
| 178 | + ] |
|
| 179 | + ]))->addField(new Field([ |
|
| 180 | 180 | 'name' => 'invalidResolveTypeMutation', |
| 181 | 181 | 'type' => new NonNullType(new IntType()), |
| 182 | 182 | 'resolve' => function () { |