Skip to content
This repository has been archived by the owner on Dec 3, 2019. It is now read-only.

Commit

Permalink
Merge pull request #205 from graphql/greenkeeper/codemirror-5.27.2
Browse files Browse the repository at this point in the history
chore(package): update codemirror to version 5.27.2
  • Loading branch information
wincent authored Jun 26, 2017
2 parents 8658193 + a82041d commit e956f8c
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 22 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@
"babel-plugin-transform-regenerator": "6.24.1",
"chai": "4.0.1",
"chai-subset": "1.5.0",
"codemirror": "5.22.2",
"codemirror": "5.27.2",
"eslint": "4.1.1",
"eslint-plugin-babel": "4.1.1",
"eslint-plugin-flowtype": "2.34.0",
Expand Down
4 changes: 2 additions & 2 deletions resources/pretty.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ const {stdout, stderr, status, error} = spawnSync(executable, [
mode,
glob,
]);
const out = stdout.toString().trim();
const err = stdout.toString().trim();
const out = (stdout || '').toString().trim();
const err = (stderr || '').toString().trim();

function print(message) {
if (message) {
Expand Down
4 changes: 2 additions & 2 deletions src/__tests__/hint-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -99,8 +99,8 @@ describe('graphql-hint', () => {

it('provides correct field name suggestion indentation', async () => {
const suggestions = await getHintSuggestions('{\n ', {line: 1, ch: 2});
expect(suggestions.from).to.deep.equal({line: 1, ch: 2});
expect(suggestions.to).to.deep.equal({line: 1, ch: 2});
expect(suggestions.from).to.deep.equal({line: 1, ch: 2, sticky: null});
expect(suggestions.to).to.deep.equal({line: 1, ch: 2, sticky: null});
});

it('provides correct argument suggestions', async () => {
Expand Down
20 changes: 10 additions & 10 deletions src/variables/__tests__/hint-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,8 @@ describe('graphql-variables-hint', () => {
'{\n ',
{line: 1, ch: 2},
);
expect(suggestions.from).to.deep.equal({line: 1, ch: 2});
expect(suggestions.to).to.deep.equal({line: 1, ch: 2});
expect(suggestions.from).to.deep.equal({line: 1, ch: 2, sticky: null});
expect(suggestions.to).to.deep.equal({line: 1, ch: 2, sticky: null});
});

it('provides correct variable completion', async () => {
Expand All @@ -91,8 +91,8 @@ describe('graphql-variables-hint', () => {
{line: 1, ch: 4},
);
checkSuggestions(['"bar": '], suggestions.list);
expect(suggestions.from).to.deep.equal({line: 1, ch: 2});
expect(suggestions.to).to.deep.equal({line: 1, ch: 4});
expect(suggestions.from).to.deep.equal({line: 1, ch: 2, sticky: null});
expect(suggestions.to).to.deep.equal({line: 1, ch: 4, sticky: null});
});

it('provides correct variable completion with open quote', async () => {
Expand All @@ -102,8 +102,8 @@ describe('graphql-variables-hint', () => {
{line: 1, ch: 4},
);
checkSuggestions(['"foo": ', '"bar": '], suggestions.list);
expect(suggestions.from).to.deep.equal({line: 1, ch: 2});
expect(suggestions.to).to.deep.equal({line: 1, ch: 3});
expect(suggestions.from).to.deep.equal({line: 1, ch: 2, sticky: null});
expect(suggestions.to).to.deep.equal({line: 1, ch: 3, sticky: null});
});

it('provides correct Enum suggestions', async () => {
Expand Down Expand Up @@ -139,8 +139,8 @@ describe('graphql-variables-hint', () => {
Object.keys(TestInput.getFields()).map(name => `"${name}": `),
suggestions.list,
);
expect(suggestions.from).to.deep.equal({line: 2, ch: 4});
expect(suggestions.to).to.deep.equal({line: 2, ch: 4});
expect(suggestions.from).to.deep.equal({line: 2, ch: 4, sticky: null});
expect(suggestions.to).to.deep.equal({line: 2, ch: 4, sticky: null});
});

it('provides correct Input Object field completion', async () => {
Expand All @@ -150,8 +150,8 @@ describe('graphql-variables-hint', () => {
{line: 2, ch: 8},
);
checkSuggestions(['"boolean": ', '"listBoolean": '], suggestions.list);
expect(suggestions.from).to.deep.equal({line: 2, ch: 4});
expect(suggestions.to).to.deep.equal({line: 2, ch: 8});
expect(suggestions.from).to.deep.equal({line: 2, ch: 4, sticky: null});
expect(suggestions.to).to.deep.equal({line: 2, ch: 8, sticky: null});
});

it('provides correct Input Object field value completion', async () => {
Expand Down
8 changes: 4 additions & 4 deletions src/variables/__tests__/lint-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,8 @@ describe('graphql-variables-lint', () => {
message: 'Expected value of type "Int".',
severity: 'error',
type: 'validation',
from: {line: 0, ch: 10},
to: {line: 0, ch: 15},
from: {line: 0, ch: 10, sticky: null},
to: {line: 0, ch: 15, sticky: null},
});
});

Expand All @@ -82,8 +82,8 @@ describe('graphql-variables-lint', () => {
message: 'Variable "$food" does not appear in any GraphQL query.',
severity: 'error',
type: 'validation',
from: {line: 0, ch: 3},
to: {line: 0, ch: 9},
from: {line: 0, ch: 3, sticky: null},
to: {line: 0, ch: 9, sticky: null},
});
});

Expand Down
6 changes: 3 additions & 3 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -674,9 +674,9 @@ code-point-at@^1.0.0:
version "1.1.0"
resolved "https://registry.yarnpkg.com/code-point-at/-/code-point-at-1.1.0.tgz#0d070b4d043a5bea33a2f1a40e2edb3d9a4ccf77"

codemirror@5.22.2:
version "5.22.2"
resolved "https://registry.yarnpkg.com/codemirror/-/codemirror-5.22.2.tgz#38274c20e3628b4f7a982bffc2cddb61ceed6a09"
codemirror@5.27.2:
version "5.27.2"
resolved "https://registry.yarnpkg.com/codemirror/-/codemirror-5.27.2.tgz#a292d42f079d5b98c68c3146fab99844f3d8776c"

combined-stream@^1.0.5, combined-stream@~1.0.5:
version "1.0.5"
Expand Down

0 comments on commit e956f8c

Please sign in to comment.