From 1c770fc33a9ad370745f86a07cc58871532ea772 Mon Sep 17 00:00:00 2001 From: Ricardo Signes Date: Wed, 30 Jan 2013 19:25:13 -0500 Subject: [PATCH] make test match error --- t/callback.t | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/t/callback.t b/t/callback.t index d8d49be..566944b 100644 --- a/t/callback.t +++ b/t/callback.t @@ -25,4 +25,8 @@ my $return = test_app('Test::WithCallback', [ qw(lol -e 2) ]); is($return->stdout, 'yay', "Callback validated correctly"); $return = test_app('Test::WithCallback', [ qw(lol -e 1) ]); -is($return->error, 'Something other than this stack trace', "Failing Params::Validate callback prints nice error message"); +like( + $return->error, + qr/even.+valid.email/, + "Failing Params::Validate callback prints nice error message" +);