Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions tsc/internal/project/contentmapper_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -679,6 +679,13 @@ func TestContentMapperOpenFileExcludedByConfigChange(t *testing.T) {
Uri: "file:///home/project/tsconfig.json",
Type: lsproto.FileChangeTypeChanged,
}})
session.WaitForBackgroundTasks()

// The background update removes app.box from the configured project, but inferred
// project cleanup is deferred until the next file open.
assert.Assert(t, session.Snapshot().GetDefaultProject(boxURI) == nil)
mainURI := lsproto.DocumentUri("file:///home/project/src/main.ts")
session.DidOpenFile(ctx, mainURI, 1, files["/home/project/src/main.ts"].(string), lsproto.LanguageKindTypeScript)

languageService, err = session.GetLanguageService(ctx, boxURI)
assert.NilError(t, err)
Expand Down