summaryrefslogtreecommitdiff
path: root/tests/unit
diff options
authorChristopher James Halse Rogers <raof@ubuntu.com>2011-12-16 15:44:26 +1100
committerChristopher James Halse Rogers <raof@ubuntu.com>2011-12-16 15:44:26 +1100
commitc69be4d134370fa2616470bb11c77cc436246890 (patch)
treeae826a5c5fb0e9ef48c85db3a95b2dda33428d35 /tests/unit
parent68b56a8b217f85556b7e3779b60bedc0198297f7 (diff)
TestStaticCairoText: UTF-8 encode the test string.
Otherwise we're relying on the encoding of the source file, which is not necessarily going to work, or work everywhere. (bzr r1738.10.7)
Diffstat (limited to 'tests/unit')
-rw-r--r--tests/unit/TestStaticCairoText.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/unit/TestStaticCairoText.cpp b/tests/unit/TestStaticCairoText.cpp
index ab2792cf6..b0bee597c 100644
--- a/tests/unit/TestStaticCairoText.cpp
+++ b/tests/unit/TestStaticCairoText.cpp
@@ -81,7 +81,10 @@ TestLeftToRightExtentIncreasesWithLength ()
static void
TestRightToLeftExtentIncreasesWithLength ()
{
- const gchar *test_string = "מחרוזת אקראית עברית";
+ // This is the UTF-8 encoding of מחרוזת אקראית עברית, a hebrew test string.
+ const gchar *test_string = "\xd7\x9e\xd7\x97\xd7\xa8\xd7\x95\xd7\x96\xd7\xaa"
+ " \xd7\x90\xd7\xa7\xd7\xa8\xd7\x90\xd7\x99\xd7\xaa"
+ "\xd7\xa2\xd7\x91\xd7\xa8\xd7\x99\xd7\xaa";
// Hebrew is an RTL language
switch_language("he");