Skip to content

Commit be909b0

Browse files
Kapil Borledaviwil
authored andcommitted
Add tests for psd1 and pester document symbols
1 parent 32207b7 commit be909b0

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

test/PowerShellEditorServices.Test/Language/LanguageServiceTests.cs

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -301,6 +301,20 @@ public void LanguageServiceFindsSymbolsInFile()
301301
//Assert.Equal(1, firstConfigurationSymbol.ScriptRegion.StartColumnNumber);
302302
}
303303

304+
[Fact]
305+
public void LanguageServiceFindsSymbolsInPesterFile()
306+
{
307+
var symbolsResult = this.FindSymbolsInFile(FindSymbolsInPesterFile.SourceDetails);
308+
Assert.Equal(5, symbolsResult.FoundOccurrences.Count());
309+
}
310+
311+
[Fact]
312+
public void LangServerFindsSymbolsInPSDFile()
313+
{
314+
var symbolsResult = this.FindSymbolsInFile(FindSymbolsInPSDFile.SourceDetails);
315+
Assert.Equal(3, symbolsResult.FoundOccurrences.Count());
316+
}
317+
304318
[Fact]
305319
public void LanguageServiceFindsSymbolsInNoSymbolsFile()
306320
{
@@ -311,7 +325,6 @@ public void LanguageServiceFindsSymbolsInNoSymbolsFile()
311325
Assert.Equal(0, symbolsResult.FoundOccurrences.Count());
312326
}
313327

314-
315328
private ScriptFile GetScriptFile(ScriptRegion scriptRegion)
316329
{
317330
string resolvedPath =

0 commit comments

Comments
 (0)