Created
June 20, 2019 14:55
-
-
Save codeitlikemiley/618baf77e645a14065cc1a6e687557c4 to your computer and use it in GitHub Desktop.
trait graphql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Tests; | |
trait GraphQLAPI | |
{ | |
/** | |
* @param string $query | |
* @return mixed | |
*/ | |
public function graphql(string $query) | |
{ | |
return $this->post('/graphql', [ | |
'query' => $query | |
]); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment