From fff905c5d3ba771adcadb49a3b13ec309fe35c64 Mon Sep 17 00:00:00 2001 From: Chris Cormack Date: Sat, 14 Jan 2012 07:28:11 +1300 Subject: [PATCH] Bug 929 : Follow up to allow tests to check plugins too --- xt/author/valid-templates.t | 19 ++++++++++++------- 1 files changed, 12 insertions(+), 7 deletions(-) diff --git a/xt/author/valid-templates.t b/xt/author/valid-templates.t index a4fa71e..202ef57 100644 --- a/xt/author/valid-templates.t +++ b/xt/author/valid-templates.t @@ -50,13 +50,18 @@ done_testing(); sub create_template_test { my $includes = shift; return sub { - my $tt = Template->new({ABSOLUTE => 1, - INCLUDE_PATH => $includes }); - my $vars; - my $output; - if ( ! ok($tt->process($_,$vars,\$output), $_) ){ - diag($tt->error); - } + my $tt = Template->new( + { + ABSOLUTE => 1, + INCLUDE_PATH => $includes, + PLUGIN_BASE => 'Koha::Template::Plugin', + } + ); + my $vars; + my $output; + if ( !ok( $tt->process( $_, $vars, \$output ), $_ ) ) { + diag( $tt->error ); + } } } -- 1.7.5.4