Fix util tests.
This commit is contained in:
parent
d6118c1cbf
commit
01942bd164
1 changed files with 3 additions and 3 deletions
|
@ -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):
|
||||
|
|
Loading…
Reference in a new issue