From febc1e8bd0563b5e0c00f828348bbd5b0d404996 Mon Sep 17 00:00:00 2001 From: Mark Kraus Date: Thu, 18 Jan 2018 16:07:06 -0600 Subject: [PATCH] Stop HttpListener from running in WebCmdlet tests (#5921) --- .../WebCmdlets.Tests.ps1 | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/test/powershell/Modules/Microsoft.PowerShell.Utility/WebCmdlets.Tests.ps1 b/test/powershell/Modules/Microsoft.PowerShell.Utility/WebCmdlets.Tests.ps1 index 41d4af520..8d0856b8a 100644 --- a/test/powershell/Modules/Microsoft.PowerShell.Utility/WebCmdlets.Tests.ps1 +++ b/test/powershell/Modules/Microsoft.PowerShell.Utility/WebCmdlets.Tests.ps1 @@ -373,15 +373,9 @@ if ( test-path /etc/centos-release ) { $PendingCertificateTest = $true } Describe "Invoke-WebRequest tests" -Tags "Feature" { BeforeAll { - $response = Start-HttpListener -Port 8080 $WebListener = Start-WebListener } - AfterAll { - $null = Stop-HttpListener -Port 8080 - $response.PowerShell.Dispose() - } - # Validate the output of Invoke-WebRequest # function ValidateResponse { @@ -1419,15 +1413,9 @@ Describe "Invoke-WebRequest tests" -Tags "Feature" { Describe "Invoke-RestMethod tests" -Tags "Feature" { BeforeAll { - $response = Start-HttpListener -Port 8081 $WebListener = Start-WebListener } - AfterAll { - $null = Stop-HttpListener -Port 8081 - $response.PowerShell.Dispose() - } - #User-Agent changes on different platforms, so tests should only be run if on the correct platform It "Invoke-RestMethod returns Correct User-Agent on MacOSX" -Skip:(!$IsMacOS) { $uri = Get-WebListenerUrl -Test 'Get'