Skip to content

Commit

Permalink
Tests are more leanient to allow error wrapping
Browse files Browse the repository at this point in the history
  • Loading branch information
aramprice committed Jul 19, 2024
1 parent bb87216 commit 8ecaf3b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions integration/construct/winrm_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ var _ = Describe("WinRM Remote Manager", func() {
It("fails when Extract-Archive powershell function returns non-zero exit code", func() {
err := rm.ExtractArchive("C:\\provision\\NonExistingFile.zip", "C:\\provision")
Expect(err).To(HaveOccurred())
Expect(err.Error()).To(HavePrefix("powershell encountered an issue: "))
Expect(err.Error()).To(ContainSubstring("powershell encountered an issue: "))
})
})

Expand All @@ -51,7 +51,7 @@ var _ = Describe("WinRM Remote Manager", func() {
It("fails when powershell command returns non-zero exit code", func() {
_, err := rm.ExecuteCommand("powershell.exe notRealCommand")
Expect(err).To(HaveOccurred())
Expect(err.Error()).To(HavePrefix("powershell encountered an issue: "))
Expect(err.Error()).To(ContainSubstring("powershell encountered an issue: "))
})
})
})

0 comments on commit 8ecaf3b

Please sign in to comment.