xref: /freebsd/crypto/openssl/external/perl/Text-Template-1.56/t/inline-comment.t (revision 0fca6ea1d4eea4c934cfff25ac9ee8ad6fe95583)
1#!perl
2#
3# Test for comments within an inline code block
4
5use strict;
6use warnings;
7use Test::More tests => 2;
8
9use_ok 'Text::Template' or exit 1;
10
11my $tmpl = Text::Template->new(
12    TYPE => 'STRING',
13    SOURCE => "Hello {\$name#comment}");
14
15my $vars = { name => 'Bob' };
16
17is $tmpl->fill_in(HASH => $vars), 'Hello Bob';
18