Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Mouse CPAN distribution.

Report information
The Basics
Id: 41254
Status: resolved
Priority: 0/
Queue: Mouse

People
Owner: Nobody in particular
Requestors: TJC [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 0.11
Fixed in: (no value)



Subject: Mouse fails to pass tests on Debian Etch
Mouse fails its own unit tests on a Debian Etch system. (ie. Core perl is a bit older than current) Logs attached from 'make test':
Subject: make_test.txt
PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'inc', 'blib/lib', 'blib/arch')" t/*.t t/000-load.......................# Soft dependency versions: # Scalar::Util: 1.19 # Test::Exception: 0.21 # MRO::Compat: 0.09 # Class::MOP: 0.69 # Moose: 0.61 # Class::Method::Modifiers: ok t/001-strict.....................ok t/002-warnings...................ok t/003-mouse-object...............ok t/004-auto-subclass..............ok t/005-extends....................ok t/006-unimport...................ok t/007-attributes.................ok t/008-default....................ok t/009-default-code...............ok t/010-required...................ok t/011-lazy.......................ok t/012-predicate..................ok t/013-clearer....................ok t/014-build......................ok t/015-demolish...................ok t/016-trigger....................ok t/017-default-reference..........Can't locate object method "code" via package "Class" at t/017-default-reference.t line 47. # Looks like you planned 8 tests but ran 5. # Looks like your test exited with 255 just after 5. Dubious, test returned 255 (wstat 65280, 0xff00) Failed 3/8 subtests t/018-multiattr-has..............ok t/019-handles....................ok t/020-load-class.................ok t/021-weak-ref...................ok t/022-init-arg...................ok t/023-builder....................ok t/024-isa........................ok t/025-more-isa...................ok t/026-auto-deref.................ok t/027-modifiers..................skipped: Class::Method::Modifiers required for this test t/028-subclass-attr..............ok t/029-new........................ok t/030-has-plus...................ok t/031-clone......................ok t/032-buildargs..................ok t/100-meta-class.................ok t/101-meta-attribute.............ok t/201-squirrel...................ok t/202-squirrel-role..............ok t/301-bugs-non-mouse............. # Failed test 'inherit attr when @ISA contains a non Mouse class before a Mouse class with the base attr' # at t/301-bugs-non-mouse.t line 25. # died: Could not find an attribute by the name of 'foo' to inherit from at /home/tobyc/tmp/Mouse-0.11/blib/lib/Mouse/Meta/Attribute.pm line 350 # Mouse::Meta::Attribute::get_parent_args() called at /home/tobyc/tmp/Mouse-0.11/blib/lib/Mouse/Meta/Attribute.pm line 334 # Mouse::Meta::Attribute::clone_parent() called at /home/tobyc/tmp/Mouse-0.11/blib/lib/Mouse.pm line 29 # Test::Exception::_try_as_caller() called at /usr/share/perl5/Test/Exception.pm line 167 # Test::Exception::lives_ok() called at t/301-bugs-non-mouse.t line 25 # Failed test 'inherited attribute' # at t/301-bugs-non-mouse.t line 31. # got: undef # expected: 'the default' # Looks like you failed 2 tests of 2. Dubious, test returned 2 (wstat 512, 0x200) Failed 2/2 subtests t/400-define-role................ok t/401-meta-role..................ok t/402-attribute-application......Can't call method "default" on an undefined value at t/402-attribute-application.t line 49. # Looks like you planned 11 tests but ran 4. # Looks like your test exited with 255 just after 4. Dubious, test returned 255 (wstat 65280, 0xff00) Failed 7/11 subtests t/403-method-modifiers...........skipped: Class::Method::Modifiers required for this test t/500_moose_extends_mouse........ok t/600-tiny-tiny..................ok t/601-tiny-mouse.................ok t/602-mouse-tiny.................ok Test Summary Report ------------------- t/017-default-reference.t (Wstat: 65280 Tests: 5 Failed: 0) Non-zero exit status: 255 Parse errors: Bad plan. You planned 8 tests but ran 5. t/301-bugs-non-mouse.t (Wstat: 512 Tests: 2 Failed: 2) Failed tests: 1-2 Non-zero exit status: 2 t/402-attribute-application.t (Wstat: 65280 Tests: 4 Failed: 0) Non-zero exit status: 255 Parse errors: Bad plan. You planned 11 tests but ran 4. Files=46, Tests=2145, 3 wallclock secs ( 0.29 usr 0.13 sys + 2.32 cusr 0.51 csys = 3.25 CPU) Result: FAIL Failed 3/46 test programs. 2/2145 subtests failed. make: *** [test_dynamic] Error 255
Hi TJC, Sorry Mouse doesn't just pass tests for you. I'll be happy to work with you to get you going. The bug you're seeing in (this stripped down version of) t/017-default- reference.t is that: package Class; use Mouse; lives_ok { has code => ( is => 'rw', ); }; Class->can('code'); returns false. The only reason that could be is the lives_ok. Take away the lives_ok and this pattern is all over the test suite, so many more tests would fail. In fact.. the two other failures you're seeing are closely linked to lives_ok. I'd put money on Test::Exception being the culprit. You have 0.21, the current version of 0.27. If an upgrade doesn't fix it, we can trace the code to figure out what the exact cause is and file a bug report for Test::Exception. If an upgrade fixes it I'll bump the dep in Mouse's Makefile.PL. Oh, hey, Aristotle, so is Test::Exception a worthy dependency for Catalyst? :P
Hi, Your suggestion was well made. Upgrading Test::Exception to 0.27 results in Mouse fully passing its tests. Guess Mouse needs the reqs upped then? Thanks for the fast help!
On Thu Nov 27 18:32:04 2008, TJC wrote: Show quoted text
> Hi, > Your suggestion was well made. > Upgrading Test::Exception to 0.27 results in Mouse fully passing its
tests. Excellent! Show quoted text
> Guess Mouse needs the reqs upped then?
I've done so. I'm going to implement one or two more things then upload 0.12 with the (sort of) dep bump. Show quoted text
> Thanks for the fast help!
No problem, Shawn