[Catalyst] Test failures in Catalyst-Plugin-Authorization-Roles-0.04

Ton Voon ton.voon at altinity.com
Fri Oct 13 15:57:55 CEST 2006


On 13 Oct 2006, at 14:15, Nigel Metheringham wrote:

> I'm posting this to the list because there was a vague recollection
> on irc that this problem had been seen before and mentioned here (but
> I couldn't find it on a quick trawl).
>
> When building Catalyst::Plugin::Authorization::Roles on Mac OS X 10.4
> (perl 5.8.6, using a fresh Cat and related modules install) I got a
> whole batch of test failures:-
>
>    t/basic............
>    #   Failed test 'existing role is OK'
>    #   in t/basic.t at line 29.
>    # died: Undefined method debug at
> Catalyst::Plugin::Authorization::Roles
>      .../blib/lib/Catalyst/Plugin/Authorization/Roles.pm 54
>
> All subsequent tests in that file, and the ones in hash_user.t fail
> in the same way - bombing whenever $c->debug was used.
>
> I couldn't work out *why* this was happening, and if I blocked that
> error by adding
> 	$c->mock(debug => sub {});
> after $c was defined, all the tests ran successfully.
>
> So it looks like there is an issue with MockObject somewhere.
>

Hi Nigel,

I mentioned this in an email to the Catalyst-dev mailing list titled  
"Test::MockObject::Extends 1.07 breaks some plugin tests" where I said:

-----

I'm working on an internal minicpan to ease our installation of  
Catalyst and found that there is a new version of  
Test::MockObject::Extends which will die if a method is unhandled:  
http://search.cpan.org/src/CHROMATIC/Test-MockObject-1.07/Changes

-----

The line you've entered is the same as I what I used to patch  
Catalyst::Plugin::Authentication::Credential::HTTP.

Ton

http://www.altinity.com
T: +44 (0)870 787 9243
F: +44 (0)845 280 1725
Skype: tonvoon


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.rawmode.org/pipermail/catalyst/attachments/20061013/12aba12d/attachment.htm 


More information about the Catalyst mailing list