File: Template-Plugin-Textile2.t

package info (click to toggle)
libtemplate-plugin-textile2-perl 1.21-4
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 76 kB
  • ctags: 3
  • sloc: perl: 31; makefile: 2
file content (31 lines) | stat: -rw-r--r-- 466 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
use Test::More tests => 1;

use strict;
use Template;

# ### Basic Textile ####

my $template_source = "
[%- USE Textile2 -%]
[%- FILTER textile2 -%]
This is *bold* and this is _italic_.
[%- END -%]
";

my $t = Template->new();

my $output;
$t->process(\$template_source, undef, \$output) or die "Can't process template";

ok( $output eq '<p>This is <strong>bold</strong> and this is <em>italic</em>.</p>' );

# ### No-HTML ###

#TODO

# ### Inline ####

#TODO

1;