diff --git a/test/powershell/Language/Scripting/Debugging/DebuggerScriptTests.Tests.ps1 b/test/powershell/Language/Scripting/Debugging/DebuggerScriptTests.Tests.ps1 index f574fba57..1cf588427 100644 --- a/test/powershell/Language/Scripting/Debugging/DebuggerScriptTests.Tests.ps1 +++ b/test/powershell/Language/Scripting/Debugging/DebuggerScriptTests.Tests.ps1 @@ -214,8 +214,8 @@ Describe "Line breakpoints on commands in multi-line pipelines" -Tags "CI" { 1..3 | ForEach-Object { $_ } | sort-object | get-unique' - $a = New-Object -ComObject Scripting.FileSystemObject - $f = $a.GetFile($scriptPath1) + $a = New-Object -ComObject Scripting.FileSystemObject + $f = $a.GetFile($scriptPath1) $scriptPath2 = $f.ShortPath $breakpoints = Set-PSBreakpoint $scriptPath2 1,2,3 -Action { continue } diff --git a/test/tools/Modules/PSSysLog/PSSysLog.psm1 b/test/tools/Modules/PSSysLog/PSSysLog.psm1 index 78819ec3d..660e98226 100644 --- a/test/tools/Modules/PSSysLog/PSSysLog.psm1 +++ b/test/tools/Modules/PSSysLog/PSSysLog.psm1 @@ -1068,17 +1068,17 @@ function Wait-PSWinEvent $All ) -    $startTime = [DateTime]::Now + $startTime = [DateTime]::Now $lastFoundCount = 0; -    do -    { -        Start-Sleep -Seconds $pause + do + { + Start-Sleep -Seconds $pause $recordsToReturn = @() -        foreach ($thisRecord in (Get-WinEvent -FilterHashtable $filterHashtable -Oldest 2> $null)) -        { + foreach ($thisRecord in (Get-WinEvent -FilterHashtable $filterHashtable -Oldest 2> $null)) + { if($PSCmdlet.ParameterSetName -eq "ByPropertyName") { if ($thisRecord."$propertyName" -like "*$propertyValue*") @@ -1108,7 +1108,7 @@ function Wait-PSWinEvent } } } -        } + } if($recordsToReturn.Count -gt 0) { @@ -1119,7 +1119,7 @@ function Wait-PSWinEvent $lastFoundCount = $recordsToReturn.Count } -    } while (([DateTime]::Now - $startTime).TotalSeconds -lt $timeout) + } while (([DateTime]::Now - $startTime).TotalSeconds -lt $timeout) } #endregion eventlog support diff --git a/test/tools/OpenCover/OpenCover.psm1 b/test/tools/OpenCover/OpenCover.psm1 index eef32740b..45d5c682a 100644 --- a/test/tools/OpenCover/OpenCover.psm1 +++ b/test/tools/OpenCover/OpenCover.psm1 @@ -31,7 +31,7 @@ function Get-ClassCoverageData([xml.xmlelement]$element) $classes = [system.collections.arraylist]::new() foreach ( $class in $element.classes.class ) { - # skip classes with names like <>f__AnonymousType6`4 + # skip classes with names like <>f__AnonymousType6`4 if ( $class.fullname -match "<>" ) { continue } $name = $class.fullname $branch = $class.summary.branchcoverage