in reply to Keeping SKIP Test Blocks Under Control
The code you posted is equivalent to this code:
# $mech is a previously-intitlized WWW::Mechanize # instance currently holding the page I want to test SKIP: { ok( $mech->response->is_success, "Request is successful" ) or skip "Unsuccessful request", 4; # ignoring repeated is_html test in original post ok( $mech->is_html, "Returns HTML" ) or skip "Didn't return HTML", 3; ok( $mech->title eq 'some title', "Returns expected title" ); my @forms = $mech->forms; ok( @forms >= 1, "Has at least one form" ) or skip "Need at least one form to work on", 1; my ($passwd_form) = @forms; ok( $passwd_form->action eq 'example.cgi', "action goes to correct CGI" ); }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
•Re: Re: Keeping SKIP Test Blocks Under Control
by merlyn (Sage) on Apr 12, 2004 at 17:37 UTC | |
by fizbin (Chaplain) on Apr 12, 2004 at 18:07 UTC | |
|
Re: Re: Keeping SKIP Test Blocks Under Control
by hardburn (Abbot) on Apr 12, 2004 at 17:39 UTC |