Compare commits
2
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6cae190a7a | ||
|
|
165c3b39f2 |
@@ -1,5 +1,9 @@
|
||||
Revision history for MojoX-Renderer-TT
|
||||
|
||||
0.21 July 29, 2009
|
||||
- Update stash key from 'template_path' to 'template' to
|
||||
match mojo change (Sebastian Knapp)
|
||||
|
||||
0.20 December 9, 2008
|
||||
- Updates to work with Mojo 0.9
|
||||
- Add default INCLUDE_PATH
|
||||
|
||||
+1
-1
@@ -13,7 +13,7 @@ WriteMakefile(
|
||||
PL_FILES => {},
|
||||
PREREQ_PM => {
|
||||
'Test::More' => 0,
|
||||
'Mojo' => 0.9,
|
||||
'Mojo' => 0.991237,
|
||||
'Template' => 2.18,
|
||||
},
|
||||
dist => { COMPRESS => 'gzip -9f', SUFFIX => 'gz', },
|
||||
|
||||
@@ -8,7 +8,7 @@ use Template ();
|
||||
use Carp ();
|
||||
use File::Spec ();
|
||||
|
||||
our $VERSION = '0.20';
|
||||
our $VERSION = '0.21';
|
||||
|
||||
__PACKAGE__->attr('tt', chained => 1);
|
||||
|
||||
@@ -52,7 +52,7 @@ sub _init {
|
||||
sub _render {
|
||||
my ($self, $renderer, $c, $output) = @_;
|
||||
|
||||
my $template_path = $c->stash->{template_path};
|
||||
my $template_path = $c->stash->{template};
|
||||
|
||||
unless (
|
||||
$self->tt->process(
|
||||
|
||||
+2
-2
@@ -17,13 +17,13 @@ my $mt = MojoX::Renderer::TT->build;
|
||||
my $output;
|
||||
my $rv;
|
||||
|
||||
$c->stash->{template_path} = 't/render/template.tt2';
|
||||
$c->stash->{template} = 't/render/template.tt2';
|
||||
|
||||
$rv = $mt->(undef, $c, \$output);
|
||||
is($rv, 1);
|
||||
is($output, "4\n");
|
||||
|
||||
$c->stash->{template_path} = 't/render/error.tt2';
|
||||
$c->stash->{template} = 't/render/error.tt2';
|
||||
$rv = $mt->(undef, $c, \$output);
|
||||
is($rv, 0);
|
||||
ok($output);
|
||||
|
||||
Reference in New Issue
Block a user