summaryrefslogtreecommitdiff
path: root/t/04-xml.t
blob: 606e06d34483587a00ebb9d7f74c5354b601c2e3 (plain)
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
#!perl 
use Test::Most 'no_plan','die';
use strict;
use warnings;
use Tree::Template::Declare options => {builder => '+LibXML'};
use Data::Dumper;
 
my $tree=tree {
    node {
        name 'stuff';
        node {
            name 'elem1';
            attribs id => 1;
            node {
                name 'sub1';
            }
        };
        node {
            name 'elem2';
            attribs id => 2;
        };
    };
};
 
diag $tree->serialize();