summaryrefslogtreecommitdiff
path: root/python3/httplib2test.py
diff options
context:
space:
mode:
Diffstat (limited to 'python3/httplib2test.py')
-rwxr-xr-xpython3/httplib2test.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/python3/httplib2test.py b/python3/httplib2test.py
index 5f786bd..246956a 100755
--- a/python3/httplib2test.py
+++ b/python3/httplib2test.py
@@ -1235,6 +1235,12 @@ class HttpPrivateTest(unittest.TestCase):
self.assertTrue('cache-control' in h)
self.assertTrue('other' in h)
self.assertEqual('Stuff', h['other'])
+
+ def testConvertByteStr(self):
+ with self.assertRaises(TypeError):
+ httplib2._convert_byte_str(4)
+ self.assertEqual('Hello World', httplib2._convert_byte_str(b'Hello World'))
+ self.assertEqual('Bye World', httplib2._convert_byte_str('Bye World'))
def testExpirationModelTransparent(self):
# Test that no-cache makes our request TRANSPARENT