Fix util tests.

This commit is contained in:
Bastian Kleineidam 2013-02-13 20:02:57 +01:00
parent d6118c1cbf
commit 01942bd164

View file

@ -14,13 +14,13 @@ class URLTest(TestCase):
def test_unescape(self):
# Test HTML replacement.
self.assertEqual(unescape('foo&bar'), 'foo&bar')
self.assertEqual(unescape('foo bar'), 'foo%C2%A0bar')
self.assertEqual(unescape('"foo"'), '%22foo%22')
self.assertEqual(unescape('foo bar'), u'foo\xa0bar')
self.assertEqual(unescape('"foo"'), '"foo"')
def test_normalisation(self):
# Test URL normalisation.
self.assertEqual(normaliseURL('http://example.com//bar/baz&baz'),
'http://example.com/bar/baz&baz')
u'http://example.com/bar/baz%26baz')
class RegexTest(TestCase):