Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
5be7ce3
commit 229545f
Showing
10 changed files
with
213 additions
and
4 deletions.
There are no files selected for viewing
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,5 +11,6 @@ coverage | |
npmDist | ||
denoDist | ||
benchmarkDist | ||
integrationTmp | ||
npm | ||
deno |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
# TBD |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
import { GraphQLString, GraphQLSchema, GraphQLObjectType } from 'graphql/type'; | ||
import { ExecutionResult } from 'graphql/execution'; | ||
import { graphqlSync } from 'graphql'; | ||
|
||
const queryType: GraphQLObjectType = new GraphQLObjectType({ | ||
name: 'Query', | ||
fields: { | ||
sayHi: { | ||
type: GraphQLString, | ||
args: { | ||
who: { type: GraphQLString }, | ||
}, | ||
resolve: (_root, args) => 'Hello ' + (args.who || 'World'), | ||
}, | ||
}, | ||
}); | ||
|
||
const schema: GraphQLSchema = new GraphQLSchema({ | ||
query: queryType, | ||
}); | ||
|
||
const result: ExecutionResult = graphqlSync({ | ||
schema, | ||
source: ` | ||
query helloWho($who: String){ | ||
test(who: $who) | ||
} | ||
`, | ||
variableValues: { who: 'Dolly' }, | ||
}); |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
{ | ||
"version": "1.0.0", | ||
"scripts": { | ||
"test": "node test.js", | ||
"test-3.8": "tsc test.ts", | ||
"test-3.9": "tsc test.ts" | ||
}, | ||
"dependencies": { | ||
"@types/node": "10.12.21", | ||
"graphql": "file:../../npmDist", | ||
"typescript-2.6": "npm:typescript@2.6.x", | ||
"typescript-2.7": "npm:typescript@2.7.x", | ||
"typescript-2.8": "npm:typescript@2.8.x", | ||
"typescript-2.9": "npm:typescript@2.9.x", | ||
"typescript-3.0": "npm:typescript@3.0.x", | ||
"typescript-3.1": "npm:typescript@3.1.x", | ||
"typescript-3.2": "npm:typescript@3.2.x", | ||
"typescript-3.3": "npm:typescript@3.3.x", | ||
"typescript-3.4": "npm:typescript@3.4.x", | ||
"typescript-3.5": "npm:typescript@3.5.x", | ||
"typescript-3.6": "npm:typescript@3.6.x", | ||
"typescript-3.7": "npm:typescript@3.7.x", | ||
"typescript-3.8": "npm:typescript@3.8.x", | ||
"typescript-3.9": "npm:typescript@3.9.x" | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
// @noflow | ||
|
||
'use strict'; | ||
|
||
const path = require('path'); | ||
const childProcess = require('child_process'); | ||
|
||
const { dependencies } = require('./package.json'); | ||
|
||
const tsVersions = Object.keys(dependencies) | ||
.filter((pkg) => pkg.startsWith('typescript-')) | ||
.sort((a, b) => b.localeCompare(a)); | ||
|
||
for (const version of tsVersions) { | ||
console.log(`Testing on ${version} ...`); | ||
|
||
const tscPath = path.join(__dirname, 'node_modules', version, 'bin/tsc'); | ||
childProcess.execSync(tscPath, { stdio: 'inherit' }); | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"compilerOptions": { | ||
"module": "commonjs", | ||
"lib": ["es6", "esnext.asynciterable"], | ||
"strict": true, | ||
"noEmit": true, | ||
"types": [] | ||
} | ||
} |
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