Skip to content

Commit c7107b1

Browse files
authoredDec 13, 2017
Merge pull request #20 from casskir/master
Add description field to custom-scalar type
2 parents a2b3771 + 2eee9a1 commit c7107b1

File tree

5 files changed

+6
-4
lines changed

5 files changed

+6
-4
lines changed
 

‎.travis.yml

+2-3
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ matrix:
66
fast_finish: true
77
include:
88
- php: 5.5
9-
env: GRAPHQLPHP_VERSION=0.10.*
10-
- php: 5.6
11-
env: GRAPHQLPHP_VERSION=0.10.*
9+
# - php: 5.6
10+
# env: GRAPHQLPHP_VERSION=0.10.*
1211
- php: 5.6
1312
- php: 7.0
1413
- php: 7.1

‎composer.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
},
1717
"require": {
1818
"php": "^5.4|~7.0",
19-
"webonyx/graphql-php": "^0.10.0 || ^0.11.0"
19+
"webonyx/graphql-php": "^0.11.0"
2020
},
2121
"require-dev": {
2222
"fabpot/php-cs-fixer": "^1.11",

‎src/Resources/skeleton/CustomScalarConfig.php.skeleton

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
[
22
<spaces>'name' => <name>,
3+
<spaces>'description' => <description>,
34
<spaces>'serialize' => <serialize>,
45
<spaces>'parseValue' => <parseValue>,
56
<spaces>'parseLiteral' => <parseLiteral>,

‎tests/StarWarsQueryTest.php

+1
Original file line numberDiff line numberDiff line change
@@ -365,5 +365,6 @@ public function testDateTime()
365365
'dateTime' => '2016-01-18 23:00:00',
366366
];
367367
$this->assertValidQuery($query, $expected);
368+
$this->assertEquals('The DateTime type', $this->getType('DateTime')->description);
368369
}
369370
}

‎tests/starWarsSchema.yml

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
DateTime:
33
type: custom-scalar
44
config:
5+
description: "The DateTime type"
56
serialize: ["Overblog\\GraphQLGenerator\\Tests\\DateTimeType", "serialize"]
67
parseValue: ["Overblog\\GraphQLGenerator\\Tests\\DateTimeType", "parseValue"]
78
parseLiteral: ["Overblog\\GraphQLGenerator\\Tests\\DateTimeType", "parseLiteral"]

0 commit comments

Comments
 (0)
Please sign in to comment.