Mercurial > hg > nginx-tests
diff access.t @ 392:c28ecaef065f
Tests: try_run() introduced.
This method replaces multiple ad-hoc solutions to grecefully skip tests if
nginx startup fails, e.g., due to no support for a particular directive.
author | Maxim Dounin <mdounin@mdounin.ru> |
---|---|
date | Fri, 18 Apr 2014 18:36:26 +0400 |
parents | 2da774b0fc7d |
children | 847ea345becb |
line wrap: on
line diff
--- a/access.t +++ b/access.t @@ -82,14 +82,7 @@ http { EOF -eval { - open OLDERR, ">&", \*STDERR; close STDERR; - $t->run(); - open STDERR, ">&", \*OLDERR; -}; -plan(skip_all => 'no inet6 and/or unix support') if $@; - -$t->plan(12); +$t->try_run('no inet6 and/or unix support')->plan(12); ###############################################################################