summaryrefslogtreecommitdiffstats
path: root/t
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2012-10-14 16:05:32 -0500
committerJesse Luehrs <doy@tozt.net>2012-10-14 16:05:32 -0500
commitb20f7783d7ff7d0b5f2fff8f3b4203dd5ef1879d (patch)
tree3d404816eac5895641ea388e8559a4f0fd603651 /t
parentc072c0248a39b8fedeee50e48c9b73611e38f412 (diff)
downloadmoosex-validation-doctypes-b20f7783d7ff7d0b5f2fff8f3b4203dd5ef1879d.tar.gz
moosex-validation-doctypes-b20f7783d7ff7d0b5f2fff8f3b4203dd5ef1879d.zip
relax this test a bit
Diffstat (limited to 't')
-rw-r--r--t/stringify.t18
1 files changed, 10 insertions, 8 deletions
diff --git a/t/stringify.t b/t/stringify.t
index c8db5a4..0925c84 100644
--- a/t/stringify.t
+++ b/t/stringify.t
@@ -17,15 +17,17 @@ doctype 'Person' => {
my $person = find_type_constraint('Person');
my $errors = $person->validate({ foo => "bar" });
- is(
+ like(
"$errors",
- "invalid value undef for 'id'\n"
- . "invalid value undef for 'name'\n"
- . "invalid value undef for 'title'\n"
- . "extra data found:\n"
- . "{\n"
- . " 'foo' => 'bar'\n"
- . "}",
+ qr[
+ invalid\ value\ undef\ for\ 'id' \n
+ invalid\ value\ undef\ for\ 'name' \n
+ invalid\ value\ undef\ for\ 'title' \n
+ extra\ data\ found: \n
+ \s* { \s*
+ 'foo' \s* => \s* 'bar' \s*
+ \s* }
+ ]x,
"stringified properly"
);
}