Conditions | 3 |
Paths | 3 |
Total Lines | 19 |
Code Lines | 11 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
87 | public function testItSetsDeprecationReasonToNullByDefault() |
||
88 | { |
||
89 | $schema = new Issue171Schema(); |
||
90 | $processor = new Processor($schema); |
||
91 | |||
92 | $processor->processPayload($this->introspectionQuery, []); |
||
93 | $resp = $processor->getResponseData(); |
||
94 | |||
95 | $enumTypes = array_filter($resp['data']['__schema']['types'], function($type){ |
||
96 | return ($type['kind'] === 'ENUM'); |
||
97 | }); |
||
98 | |||
99 | foreach ($enumTypes as $enumType) { |
||
100 | foreach ($enumType['enumValues'] as $value) { |
||
101 | $this->assertFalse($value['isDeprecated']); |
||
102 | $this->assertNull($value['deprecationReason'], "deprecationReason should have been null"); |
||
103 | } |
||
104 | } |
||
105 | } |
||
106 | } |