Skip to content

Commit 96a10f3

Browse files
committed
Fix mock
1 parent 45f5a9e commit 96a10f3

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/Razor/test/Microsoft.AspNetCore.Razor.LanguageServer.Test/Formatting_NetFx/FormattingTestBase.cs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -347,6 +347,9 @@ internal static IDocumentSnapshot CreateDocumentSnapshot(
347347
return CreateDocumentSnapshot(
348348
path, fileKind, codeDocument, projectEngine, imports, importDocuments, tagHelpers, inGlobalNamespace);
349349
});
350+
snapshotMock
351+
.Setup(d => d.GetCSharpSyntaxTreeAsync(It.IsAny<CancellationToken>()))
352+
.ReturnsAsync(codeDocument.GetOrParseCSharpSyntaxTree(CancellationToken.None));
350353

351354
return snapshotMock.Object;
352355
}

0 commit comments

Comments
 (0)