10
10
use Rebing \GraphQL \Tests \Support \Queries \PostQuery ;
11
11
use Rebing \GraphQL \Tests \Support \Types \PostWithModelType ;
12
12
use Rebing \GraphQL \Tests \Support \Traits \SqlAssertionTrait ;
13
- use Rebing \GraphQL \Tests \Support \Queries \PostWithSelectFieldsQuery ;
13
+ use Rebing \GraphQL \Tests \Support \Queries \PostWithSelectFieldsAndModelQuery ;
14
14
use Rebing \GraphQL \Tests \Support \Queries \PostWithSelectFieldsNoModelQuery ;
15
15
16
16
class SelectFieldsTest extends TestCaseDatabase
@@ -56,15 +56,15 @@ public function testWithoutSelectFields(): void
56
56
$ this ->assertEquals ($ expectedResult , $ response ->json ());
57
57
}
58
58
59
- public function testWithSelectFields (): void
59
+ public function testWithSelectFieldsAndModel (): void
60
60
{
61
61
$ post = factory (Post::class)->create ([
62
62
'title ' => 'Title of the post ' ,
63
63
]);
64
64
65
65
$ graphql = <<<GRAQPHQL
66
66
{
67
- postWithSelectFields (id: $ post ->id ) {
67
+ postWithSelectFieldsAndModel (id: $ post ->id ) {
68
68
id
69
69
title
70
70
}
@@ -84,7 +84,7 @@ public function testWithSelectFields(): void
84
84
85
85
$ expectedResult = [
86
86
'data ' => [
87
- 'postWithSelectFields ' => [
87
+ 'postWithSelectFieldsAndModel ' => [
88
88
'id ' => '1 ' ,
89
89
'title ' => 'Title of the post ' ,
90
90
],
@@ -141,7 +141,7 @@ protected function getEnvironmentSetUp($app)
141
141
$ app ['config ' ]->set ('graphql.schemas.default ' , [
142
142
'query ' => [
143
143
PostQuery::class,
144
- PostWithSelectFieldsQuery ::class,
144
+ PostWithSelectFieldsAndModelQuery ::class,
145
145
PostWithSelectFieldsNoModelQuery::class,
146
146
],
147
147
]);
0 commit comments