introQuery = Introspection::getIntrospectionQuery(); } public function benchSchema() { StarWarsSchema::build(); } public function benchHeroQuery() { $q = ' query HeroNameQuery { hero { name } } '; GraphQL::executeQuery( StarWarsSchema::build(), $q ); } public function benchNestedQuery() { $q = ' query NestedQuery { hero { name friends { name appearsIn friends { name } } } } '; GraphQL::executeQuery( StarWarsSchema::build(), $q ); } public function benchQueryWithFragment() { $q = ' query UseFragment { luke: human(id: "1000") { ...HumanFragment } leia: human(id: "1003") { ...HumanFragment } } fragment HumanFragment on Human { name homePlanet } '; GraphQL::executeQuery( StarWarsSchema::build(), $q ); } public function benchStarWarsIntrospectionQuery() { GraphQL::executeQuery( StarWarsSchema::build(), $this->introQuery ); } }