Test that whitespace around tags and values is stripped.

This commit is contained in:
William Grant
2011-03-09 22:50:08 +11:00
parent f8fb2d952d
commit 42a463cc23
+5
View File
@@ -77,6 +77,11 @@ class TestParseTagValue(unittest.TestCase):
{'foo': 'bar', 'baz': 'foo=bar'},
parse_tag_value('foo=bar;baz=foo=bar'))
def test_whitespace_is_stripped(self):
self.assertEqual(
{'foo': 'bar', 'baz': 'f oo=bar'},
parse_tag_value(' foo \t= bar;\tbaz= f oo=bar '))
def test_missing_value_is_an_error(self):
self.assertRaises(
InvalidTagValueList,