From b19d75f9b47d3ddba0ba42fa5df11918f57d0bdb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Przemys=C5=82aw=20K=C5=82ys?= Date: Tue, 26 Nov 2019 11:52:18 +0100 Subject: [PATCH] Small test update --- PSWriteHTML.AzurePipelines.yml | 2 +- Tests/New-HTML.Tests.ps1 | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/PSWriteHTML.AzurePipelines.yml b/PSWriteHTML.AzurePipelines.yml index 22777898..0fce22ef 100644 --- a/PSWriteHTML.AzurePipelines.yml +++ b/PSWriteHTML.AzurePipelines.yml @@ -8,7 +8,7 @@ .\PSWriteHTML.Tests.ps1 displayName: "Run Pester Tests - PowerShell 5" # - script: | - # pwsh -c '.\PSBlackListChecker.Tests.ps1' $(TEAMSPESTERID) $(SLACKPESTERID) $(DISCORDURL) + # pwsh -c '.\PSWriteHTML.Tests.ps1' # displayName: "Run Pester Tests - PowerShell 6+" - job: Build_PSCore_Ubuntu1604 diff --git a/Tests/New-HTML.Tests.ps1 b/Tests/New-HTML.Tests.ps1 index 9c1e5ee9..daa2c5e3 100644 --- a/Tests/New-HTML.Tests.ps1 +++ b/Tests/New-HTML.Tests.ps1 @@ -11,7 +11,7 @@ } } It 'Given New-HTML with wrong path it should create HTML file in temporary location' { - $FilePath = "C:\TemporaryTest.html" + $FilePath = "Z:\Windows" New-HTML { } -FilePath $FilePath -WarningVariable Warnings -WarningAction SilentlyContinue @@ -25,7 +25,7 @@ $secondString = "$" $pattern = "$firstString(.*?)$secondString" $result = [regex]::Match($Warnings[1], $pattern).Groups[1].Value - Write-host $result + #Write-host $result $PathExists = ($result -and (Test-Path -LiteralPath $result)) $PathExists | Should -Be $True if ($PathExists) {