Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the WWW-Mechanize CPAN distribution.

Report information
The Basics
Id: 42121
Status: resolved
Priority: 0/
Queue: WWW-Mechanize

Owner: Nobody in particular
Requestors: jkeenan [...]

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

Subject: t/live/computers4sure.t: Failures in tests 5 and 6
Download (untitled) / with headers
text/plain 1.3k
Had to install WWW::Mechanize in order to use Parrot developer tool tools/dev/ While doing so, I experienced failures and an early exit in the file named above: $ prove -v t/live/computers4sure.t t/live/computers4sure.... 1..9 ok 1 - use WWW::Mechanize; ok 2 - Created object isa WWW::Mechanize ok 3 - Fetched ok 4 - Found a likely word in the first page not ok 5 - Should have lots of product links # Failed test 'Should have lots of product links' # at t/live/computers4sure.t line 24. # '0' # > # '10' not ok 6 - The object isa WWW::Mechanize::Link # Failed test 'The object isa WWW::Mechanize::Link' # at t/live/computers4sure.t line 27. # The object isn't defined Can't call method "url" on an undefined value at t/live/computers4sure.t line 28. # Looks like you planned 9 tests but only ran 6. # Looks like you failed 2 tests of 6 run. # Looks like your test died just after 6. Dubious, test returned 255 (wstat 65280, 0xff00) Failed 5/9 subtests Test Summary Report ------------------- t/live/computers4sure (Wstat: 65280 Tests: 6 Failed: 2) Failed tests: 5-6 Non-zero exit status: 255 Parse errors: Bad plan. You planned 9 tests but ran 6. Files=1, Tests=6, 1 wallclock secs ( 0.00 usr 0.00 sys + 0.22 cusr 0.02 csys = 0.24 CPU) Result: FAIL
Download (untitled) / with headers
text/plain 549b
The page you are linking to in this test file,, appears to have changed the way its hyperlinks are written. As a consequence, these tests are obsolete: my @links = $mech->find_all_links( url_regex => qr{product\.asp\?productid=} ); cmp_ok( scalar @links, '>', 10, 'Should have lots of product links' ); ok( scalar @links, 'Should have lots of product links' ); my $link = $links[@links/2]; # Pick one in the middle print STDERR "link: $link\n"; isa_ok( $link, 'WWW::Mechanize::Link' ); my $link_str = $link->url;
Download (untitled) / with headers
text/plain 542b
On Sa. 03. Jan. 2009, 20:13:28, JKEENAN wrote: Show quoted text
> The page you are linking to in this test file, >, appears to have > changed the way its hyperlinks are written. As a consequence, these > tests are obsolete:
Had the same problem while installing Catalyst with HTML::FormFu. As a workaround I changed the test file to fetch a product listing: #my $first_page = ''; my $first_page = ''; Now the test run successful.
Download (untitled) / with headers
text/plain 269b
I would be happy to (at least tentatively!) host content for the live tests that would never change. This bug has bitten me twice this week. I'd also supply a "run live tests?" prompt patch, like those featured in many other dists, if it will be considered. -- rjbs
This has been fixed.

This service is sponsored and maintained by Best Practical Solutions and runs on infrastructure.

Please report any issues with to