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 strict;
use warnings;
use Test::More;
use HTML::Restrict ();
my $before = <<'EOF';
two element open & close break<br></br>
one element open & close break <br />
one element open & close break no space<br/>
EOF
my $after = <<'EOF';
two element open & close break<br></br>
one element open & close break <br>
one element open & close break no space<br>
EOF
my $hr = HTML::Restrict->new(
trim => 0,
rules => {
br => [],
},
);
my $got = $hr->process($before);
is( $got, $after, '<br/> preserved' );
done_testing();
|