Skip to content

Commit

Permalink
add comments
Browse files Browse the repository at this point in the history
  • Loading branch information
acao committed Feb 27, 2024
1 parent 593eecd commit 02d6a9c
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ const genSchemaPath =
// this may be cumbersome with offset position assertions but possible
// if we can create consistency that doesn't limit variability
// - convert each it() into a nested describe() block (or a top level describe() in another file), and sprinkle in it() statements to replace comments
// - fix TODO comments where bugs were found that couldn't be resolved quickly (2-4hr timebox)
// - fix TODO comments where bugs were found that couldn't be resolved quickly (2-4hr time box)

describe('MessageProcessor with no config', () => {
afterEach(() => {
Expand Down Expand Up @@ -327,7 +327,7 @@ describe('project with simple config and graphql files', () => {
position: { character: 20, line: 17 },
});
expect(schemaDefs[0].uri).toEqual(URI.parse(genSchemaPath).toString());
// note: if the graphiql test schema changes,
// note: if the graphiql test schema changes,
// this might break, please adjust if you see a failure here
expect(serializeRange(schemaDefs[0].range)).toEqual({
start: {
Expand Down Expand Up @@ -436,7 +436,10 @@ describe('project with simple config and graphql files', () => {
// 'b/schema.graphql',
// schemaFile[1] + '\ntype Example1 { field: }',
// );
// TODO: this didn't work at all, how to register incomplete changes to model autocomplete, etc?
// TODO: this didn't work at all for multi project,
// whereas a schema change works above in a single schema context as per updating the cache
//
// how to register incomplete changes to model autocomplete, etc?
// await project.lsp.handleWatchedFilesChangedNotification({
// changes: [
// { uri: project.uri('b/schema.graphql'), type: FileChangeType.Changed },
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import { Logger as VSCodeLogger } from 'vscode-jsonrpc';
import { URI } from 'vscode-uri';
import { FileChangeType } from 'vscode-languageserver';
import { FileChangeTypeKind } from 'graphql-language-service';
import { mock } from 'fetch-mock';

export type MockFile = [filename: string, text: string];

Expand Down Expand Up @@ -74,6 +73,7 @@ export class MockProject {
loadConfigOptions: { rootDir: root },
});
}

public async init(filename?: string, fileText?: string) {
await this.lsp.handleInitializeRequest({
rootPath: this.root,
Expand Down

0 comments on commit 02d6a9c

Please sign in to comment.