public function testWithMisplacedDirectives()
{
$this->expectFailsRule(new KnownDirectives(), '
query Foo @include(if: true) {
name @operationOnly
...Frag @operationOnly
}
', [$this->misplacedDirective('include', 'QUERY', 2, 17), $this->misplacedDirective('operationOnly', 'FIELD', 3, 14), $this->misplacedDirective('operationOnly', 'FRAGMENT_SPREAD', 4, 17)]);
}