2 writes to _languageServiceProvider
Microsoft.CodeAnalysis.EditorFeatures.Test.Utilities (2)
Workspaces\TestHostDocument.cs (2)
129
_languageServiceProvider
= languageServiceProvider;
199
_languageServiceProvider
??= project.LanguageServiceProvider;
5 references to _languageServiceProvider
Microsoft.CodeAnalysis.EditorFeatures.Test.Utilities (5)
Workspaces\TestHostDocument.cs (5)
64
var workspace =
_languageServiceProvider
!.WorkspaceServices.Workspace;
253
var workspace = (TestWorkspace?)
_languageServiceProvider
?.WorkspaceServices.Workspace;
257
Contract.ThrowIfNull(
_languageServiceProvider
, $"To get a text buffer for a {nameof(TestHostDocument)}, it must have been parented in a project.");
258
var contentType =
_languageServiceProvider
.GetRequiredService<IContentTypeLanguageService>().GetDefaultContentType();
260
_textBuffer = workspace!.GetOrCreateBufferForPath(FilePath, contentType,
_languageServiceProvider
.Language, _initialText);