Skip to content

Commit

Permalink
typo in name
Browse files Browse the repository at this point in the history
  • Loading branch information
xsawyerx committed Sep 3, 2010
1 parent 1cd93b5 commit 82366c6
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions lib/Test/TinyMocker.pm
Expand Up @@ -45,19 +45,18 @@ sub mock {
}

sub unmock {

croak 'useless use of unmock without parameters'
unless scalar @_;

my $symbole = @_ == 2 ? qq{$_[0]::$_[1]} : $_[0];
my $symbol = @_ == 2 ? qq{$_[0]::$_[1]} : $_[0];

croak "unkown method $symbole"
unless $mocks->{$symbole};
croak "unkown method $symbol"
unless $mocks->{$symbol};

{
no strict 'refs';
no warnings 'redefine', 'prototype';
*{$symbole} = delete $mocks->{$symbole};
*{$symbol} = delete $mocks->{$symbol};
}
}

Expand Down

0 comments on commit 82366c6

Please sign in to comment.