File: unescapeHTML.t

package info (click to toggle)
libcgi-pm-perl 3.49-1squeeze2
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 1,044 kB
  • ctags: 354
  • sloc: perl: 6,095; makefile: 9
file content (8 lines) | stat: -rw-r--r-- 425 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
use Test::More tests => 4;
use CGI 'unescapeHTML';

is( unescapeHTML( '&'), '&', 'unescapeHTML: &');
is( unescapeHTML( '"'), '"', 'unescapeHTML: "');
is( unescapeHTML( '&#60;'), '<', 'unescapeHTML: < (using a numbered sequence)'); 
is( unescapeHTML( 'Bob & Tom went to the store; Where did you go?'), 
    'Bob & Tom went to the store; Where did you go?', 'unescapeHTML: a case where &...; should not be escaped.');