From 847171b0d09c7da95cd404bab80f84c890fc5cfd Mon Sep 17 00:00:00 2001 From: Baptiste Mispelon Date: Tue, 18 Feb 2014 18:07:07 +0100 Subject: [PATCH] Fixed test failures when running in a narrow Python build. --- tests/utils_tests/test_text.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tests/utils_tests/test_text.py b/tests/utils_tests/test_text.py index 4911cac908c..12e441b81a6 100644 --- a/tests/utils_tests/test_text.py +++ b/tests/utils_tests/test_text.py @@ -1,9 +1,13 @@ # -*- coding: utf-8 -*- from __future__ import unicode_literals +from unittest import skipUnless + from django.test import SimpleTestCase from django.utils import six, text +IS_WIDE_BUILD = (len('\U0001F4A9') == 1) + class TestUtilsText(SimpleTestCase): @@ -156,6 +160,7 @@ class TestUtilsText(SimpleTestCase): self.assertEqual(text.javascript_quote(input, quote_double_quotes=True), '"Text"') + @skipUnless(IS_WIDE_BUILD) def test_javascript_quote_unicode(self): input = "" output = r"