Last change
on this file since 100620 was 94320, checked in by vboxsync, 3 years ago |
libs/openssl-3.0.1: Export to OSE and fix copyright headers in Makefiles, bugref:10128
|
File size:
553 bytes
|
Line | |
---|
1 | #!perl
|
---|
2 | #
|
---|
3 | # Test for RT Bug 29928 fix
|
---|
4 | # https://rt.cpan.org/Public/Bug/Display.html?id=29928
|
---|
5 |
|
---|
6 | use strict;
|
---|
7 | use warnings;
|
---|
8 | use Test::More tests => 2;
|
---|
9 |
|
---|
10 | use_ok 'Text::Template::Preprocess' or exit 1;
|
---|
11 |
|
---|
12 | my $tin = q{The value of $foo is: {$foo}.};
|
---|
13 |
|
---|
14 | sub tester {
|
---|
15 | 1; # dummy preprocessor to cause the bug described.
|
---|
16 | }
|
---|
17 |
|
---|
18 | my $tmpl1 = Text::Template::Preprocess->new(TYPE => 'STRING', SOURCE => $tin);
|
---|
19 |
|
---|
20 | $tmpl1->compile;
|
---|
21 |
|
---|
22 | my $t1 = $tmpl1->fill_in(
|
---|
23 | HASH => { foo => 'things' },
|
---|
24 | PREPROCESSOR => \&tester);
|
---|
25 |
|
---|
26 | is $t1, 'The value of $foo is: things.';
|
---|
Note:
See
TracBrowser
for help on using the repository browser.