Skip to content

Commit

Permalink
test range
Browse files Browse the repository at this point in the history
  • Loading branch information
acao committed Aug 3, 2023
1 parent 2439ebc commit 6482883
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
*
*/

import { Position, Range } from 'graphql-language-service';
import { findGraphQLTags as baseFindGraphQLTags } from '../findGraphQLTags';

jest.mock('../Logger');
Expand Down Expand Up @@ -351,6 +352,10 @@ query {id}`);
}
}
`);

expect(JSON.stringify(contents[0].range)).toEqual(
JSON.stringify(new Range(new Position(2, 29), new Position(12, 0))),
);
});

it('no crash in Svelte files without <script>', async () => {
Expand Down

0 comments on commit 6482883

Please sign in to comment.