7 my $one = html('<tag>').$hi.html('</tag>');
9 is("$one", '<tag>Hi <bob></tag>');
12 use HTML::String::Overload;
17 is("$two", '<tag>Hi <bob></tag>');
19 my $three = html('<tag>');
23 $three .= html('</tag>');
25 is("$three", '<tag>Hi <bob></tag>');
28 use HTML::String::Overload { ignore => { non_existant_package_name => 1 } };
30 #$four = "<tag>".$hi."</tag>\n";
31 $four = "<tag>$hi</tag>"."\n";
36 is("$four", '<tag>Hi <bob></tag>');
46 is(html('MyPkg')->new, 'foo');
48 is(html('MyPkg')->load, 'bar');
50 # Test that all characters that should be escaped are escaped
52 my $raw_characters = q{<>&"'};
53 my $expected_output = q{<tag><>&"'</tag>};
54 my $html = html('<tag>').$raw_characters.html('</tag>');
55 is($html, $expected_output);