]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 481025 - Remove rogue Byte Order Mark.
authorwurblzap%gmail.com <>
Mon, 2 Mar 2009 21:24:28 +0000 (21:24 +0000)
committerwurblzap%gmail.com <>
Mon, 2 Mar 2009 21:24:28 +0000 (21:24 +0000)
Patch by Marc Schumann <wurblzap@gmail.com>;
r/a=mkanat

t/005whitespace.t
template/en/default/account/auth/login-small.html.tmpl

index e6bd07f4ec03e611583fbc81a54475e23a09685a..edba8b2745520a0aa8d67981dc476abdbb655c2c 100644 (file)
@@ -36,7 +36,7 @@ use Support::Templates;
 
 use File::Spec;
 use Test::More tests => (  scalar(@Support::Files::testitems)
-                         + $Support::Templates::num_actual_files) * 2;
+                         + $Support::Templates::num_actual_files) * 3;
 
 my @testitems = @Support::Files::testitems;
 for my $path (@Support::Templates::include_paths) {
@@ -68,4 +68,15 @@ foreach my $file (@testitems) {
     close (FILE);
 }
 
+foreach my $file (@testitems) {
+    open (FILE, "$file");
+    my $first_line = <FILE>;
+    if ($first_line =~ /\xef\xbb\xbf/) {
+        ok(0, "$file contains Byte Order Mark --WARNING");
+    } else {
+        ok(1, "$file is free of a Byte Order Mark");
+    }
+    close (FILE);
+}
+
 exit 0;
index fd651e71d7616d5b457b1aad27f1931d34e03fec..92901631feea6eab2da883528318822faccd756d 100644 (file)
@@ -1,4 +1,4 @@
-[%# The contents of this file are subject to the Mozilla Public
+[%# The contents of this file are subject to the Mozilla Public
   # License Version 1.1 (the "License"); you may not use this file
   # except in compliance with the License. You may obtain a copy of
   # the License at http://www.mozilla.org/MPL/