summaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
authorPaul Berry <stereotype441@gmail.com>2011-08-08 09:04:00 -0700
committerPaul Berry <stereotype441@gmail.com>2011-08-11 13:09:30 -0700
commitda3126ce20538c0906226c62c089be4965aa2e41 (patch)
tree56062c3cc2ed180bcc72b803606352a7360f229e /templates
parent4da714cd47e8a993ce26a572dd05fe8107950d46 (diff)
Changed piglit-summary-html to explicitly encode its output as UTF-8.
Previously piglit-summary-html didn't explicitly encode its output at all--it relied on the default behavior of the Python file.write() method (which, in Python 2.x, is to write 8-bit strings verbatim and to encode unicode strings using ASCII). This meant that if a non-ASCII character appeared in any of the test data, piglit-summary-html would fail with an exception. This patch changes piglit-summary-html to explicitly encode its output using UTF-8. It also updates all of the HTML templates to specify UTF-8 as the encoding, so that when results are viewed in a web browser, non-ASCII characters will display correctly.
Diffstat (limited to 'templates')
-rw-r--r--templates/index.html1
-rw-r--r--templates/result.html1
-rw-r--r--templates/testrun.html1
3 files changed, 3 insertions, 0 deletions
diff --git a/templates/index.html b/templates/index.html
index d6bf392d3..ff347df5d 100644
--- a/templates/index.html
+++ b/templates/index.html
@@ -1,5 +1,6 @@
<html>
<head>
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Result summary </title>
<link rel="stylesheet" href="index.css"/>
</head>
diff --git a/templates/result.html b/templates/result.html
index d6167e7b0..f90ff3d7a 100644
--- a/templates/result.html
+++ b/templates/result.html
@@ -1,5 +1,6 @@
<html>
<head>
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>%(path)s - Details</title>
<link rel="stylesheet" href="../result.css"/>
</head>
diff --git a/templates/testrun.html b/templates/testrun.html
index a04ec0d01..572381f30 100644
--- a/templates/testrun.html
+++ b/templates/testrun.html
@@ -1,5 +1,6 @@
<html>
<head>
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>%(name)s - System info</title>
<link rel="stylesheet" href="../result.css"/>
</head>