From 1708622c49bb109a1f25eccf187dcaa2f94cc1db Mon Sep 17 00:00:00 2001 From: Graham Ollis Date: Sat, 23 Feb 2013 03:05:25 -0500 Subject: [PATCH] testing diagnostics --- Changes | 1 + t/default_handler_no_templates_dir.t | 9 ++++++--- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/Changes b/Changes index 416cafa..cddc8d6 100644 --- a/Changes +++ b/Changes @@ -1,6 +1,7 @@ Revision history for Mojolicious::Plugin::TtRenderer {{$NEXT}} + - Additional testing diagnostics 1.40 February 20, 2013 - Added diagnostic for IO loop implementation in testing diff --git a/t/default_handler_no_templates_dir.t b/t/default_handler_no_templates_dir.t index 8e2854a..c567c06 100644 --- a/t/default_handler_no_templates_dir.t +++ b/t/default_handler_no_templates_dir.t @@ -21,11 +21,14 @@ $t->get_ok('/') ->status_is(500) ->content_like(qr{foo}); +$t->app->log->on(message => sub { + my($log, $level, @lines) = @_; + diag @lines if $level eq 'error'; +}); + $t->get_ok('/bar') ->status_is(200) - ->content_like(qr{bar}); - -#note $t->tx->res->to_string; + ->content_like(qr{sometimes, the bar,}); __DATA__