From: Ben Darnell Date: Sun, 11 Jan 2015 18:00:00 +0000 (-0500) Subject: Fix httputil_test on python 3.2. X-Git-Tag: v4.1.0b1~39 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9347de40d5da99a7659e78a9a9768b06b5fad385;p=thirdparty%2Ftornado.git Fix httputil_test on python 3.2. --- diff --git a/tornado/test/httputil_test.py b/tornado/test/httputil_test.py index 53bb4e798..3995abe8b 100644 --- a/tornado/test/httputil_test.py +++ b/tornado/test/httputil_test.py @@ -7,6 +7,7 @@ from tornado.escape import utf8, native_str from tornado.log import gen_log from tornado.testing import ExpectLog from tornado.test.util import unittest +from tornado.util import u import datetime import logging @@ -236,13 +237,13 @@ Foo: even # and cpython's unicodeobject.c (which defines the implementation # of unicode_type.splitlines(), and uses a different list than TR13). newlines = [ - u'\u001b', # VERTICAL TAB - u'\u001c', # FILE SEPARATOR - u'\u001d', # GROUP SEPARATOR - u'\u001e', # RECORD SEPARATOR - u'\u0085', # NEXT LINE - u'\u2028', # LINE SEPARATOR - u'\u2029', # PARAGRAPH SEPARATOR + u('\u001b'), # VERTICAL TAB + u('\u001c'), # FILE SEPARATOR + u('\u001d'), # GROUP SEPARATOR + u('\u001e'), # RECORD SEPARATOR + u('\u0085'), # NEXT LINE + u('\u2028'), # LINE SEPARATOR + u('\u2029'), # PARAGRAPH SEPARATOR ] for newline in newlines: # Try the utf8 and latin1 representations of each newline