Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -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 {
Expand Down Expand Up @@ -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'
Expand Down