Doozer has asked for the wisdom of the Perl Monks concerning the following question:
I am using Test::More in conjunction with Test::WWW::Selenium to run automated web browser tests. I have read the info on the CPAN man page about Test::More but am struggling to get my head around the SKIP function.
In my script I have a test that checks if the title of a web page matches a regular expression that I have defined (shown below).
like($sel->get_title(), 'm/Broadband Connection \| Congratulations/', "Parental control hijack page was seen after the router was factory reset");I would like to make it so if the title does not match the regular expression (and therefore that test fails), the following 3 tests after it are skipped.
I have a feeling its quite straight forward but I cant seem to get my head around how to do it.
Any help would be much appreciated and more info can be provided if needed.
Thanks!
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Test::More - Skip following tests if one test fails
by tmharish (Friar) on Feb 28, 2013 at 11:38 UTC | |
|
Re: Test::More - Skip following tests if one test fails
by tobyink (Canon) on Feb 28, 2013 at 12:27 UTC | |
by Doozer (Scribe) on Feb 28, 2013 at 12:49 UTC | |
by Edster (Initiate) on May 27, 2014 at 13:29 UTC | |
by tye (Sage) on May 27, 2014 at 15:31 UTC | |
|
Re: Test::More - Skip following tests if one test fails
by kcott (Archbishop) on Mar 01, 2013 at 03:54 UTC |