From 4dc3bd5e355461042402e55f6242e17a07cb4e2d 2014-12-17 19:38:46 From: Scott Sanderson Date: 2014-12-17 19:38:46 Subject: [PATCH] BUG: Convert to bytes before comparing binary blobs. --- diff --git a/IPython/html/services/contents/tests/test_contents_api.py b/IPython/html/services/contents/tests/test_contents_api.py index 36e849a..ac8f142 100644 --- a/IPython/html/services/contents/tests/test_contents_api.py +++ b/IPython/html/services/contents/tests/test_contents_api.py @@ -289,7 +289,7 @@ class APITest(NotebookTestBase): self.assertEqual(model['format'], 'base64') self.assertEqual(model['type'], 'file') self.assertEqual( - base64.decodestring(model['content']), + base64.decodestring(model['content'].encode('ascii')), self._blob_for_name(name), )