There's more than one way to do things | |
PerlMonks |
Test::More - Skip following tests if one test failsby Doozer (Scribe) |
on Feb 28, 2013 at 10:42 UTC ( [id://1021037]=perlquestion: print w/replies, xml ) | Need Help?? |
Doozer has asked for the wisdom of the Perl Monks concerning the following question:
Hello!
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!
Back to
Seekers of Perl Wisdom
|
|