File: 06-package.t

package info (click to toggle)
libtext-microtemplate-perl 0.18-1
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 272 kB
  • sloc: perl: 1,563; makefile: 2
file content (14 lines) | stat: -rw-r--r-- 316 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
use strict;
use warnings;
use Test::More tests => 2;
use Text::MicroTemplate qw(:all);

is render_mt('<?= __PACKAGE__ ?>')->as_string, 'main', 'default package';
is(
    render_mt({
        package_name => 'foo',
        template     => '<?= __PACKAGE__ ?>',
    })->as_string,
    'foo',
    'explicit package',
);