Skip to content

Commit

Permalink
Adding failing test
Browse files Browse the repository at this point in the history
  • Loading branch information
dlwyatt committed Dec 10, 2015
1 parent 85eb5fe commit 9b6753f
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions Functions/Mock.Tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -1507,3 +1507,12 @@ Describe 'Assert-MockCalled with Aliases' {
{ Assert-MockCalled TestFunction } | Should Not Throw
}
}

Describe 'Mocking Get-Command' {
# This was reported as a bug in 3.3.12; we were relying on Get-Command to safely invoke other commands.
# Mocking Get-Command, though, would result in infinite recursion.

It 'Does not break when Get-Command is mocked' {
{ Mock Get-Command } | Should Not Throw
}
}

0 comments on commit 9b6753f

Please sign in to comment.