develooper Front page | perl.perl5.porters | Postings from October 2000

[PATCH: perl@7483] fix coded control chars in cgi-html.t

Thread Previous | Thread Next
Peter Prymmer
October 30, 2000 17:45
[PATCH: perl@7483] fix coded control chars in cgi-html.t
Message ID:

File affected:


Here is the patch:

--- t/lib/cgi-html.t.orig	Mon Oct 30 17:33:41 2000
+++ t/lib/cgi-html.t	Mon Oct 30 17:38:52 2000
@@ -82,7 +82,12 @@
 test(20,start_table({-border=>undef}) eq '<table border>');
 test(21,h1(escapeHTML("this is <not> \x8bright\x9b")) eq '<h1>this is &lt;not&gt; &#139;right&#155;</h1>');
+if (ord("\t") == 9) {
 test(22,h1(escapeHTML("this is <not> \x8bright\x9b")) eq '<h1>this is &lt;not&gt; ‹right›</h1>');
+else {
+test(22,h1(escapeHTML("this is <not> \x8bright\x9b")) eq '<h1>this is &lt;not&gt; »rightº</h1>');
 test(23,i(p('hello there')) eq '<i><p>hello there</p></i>');
 my $q = new CGI;
 test(24,$q->h1('hi') eq '<h1>hi</h1>');
End of Patch.

Peter Prymmer

Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About