forked from dotnet/roslyn
-
Notifications
You must be signed in to change notification settings - Fork 0
/
run_tests_iter.ps1
32 lines (30 loc) · 938 Bytes
/
run_tests_iter.ps1
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
function RunTest
{
Write-Host "Running..."
Remove-Item C:\cores\*
dotnet test .\artifacts\bin\Microsoft.CodeAnalysis.EditorFeatures.UnitTests\Debug\net472\Microsoft.CodeAnalysis.EditorFeatures.UnitTests.dll --filter "FullyQualifiedName=Microsoft.CodeAnalysis.Editor.UnitTests.CommentSelection.ToggleBlockCommentCommandHandlerTests.Throws" --blame
$childItems = Get-ChildItem C:\cores -Name -Include *.dmp
$HasDump = $false
if ($childItems)
{
$HasDump = $childItems.Contains("testhost.net472")
}
if (Get-Process -Name "WerFault.exe" -ea SilentlyContinue)
{
Write-Host "Wer RUNNING!!!!"
$HasDump = $true
}
Remove-Item C:\cores\*
Write-Host "Completed with $HasDump"
return $HasDump
}
$count = 0
1..10 | ForEach-Object {
$result = RunTest
Write-Host "Result $result"
if ($result -eq $true)
{
$count++
}
}
Write-Host "Count: $count"