Pillow/test/test_image_tobitmap.py
Alex Clark 7a866e7431 Revert "Fix broken py3 tests"
This reverts commit 0c47ce00b1.
2014-06-09 20:56:29 -04:00

23 lines
465 B
Python

from helper import unittest, PillowTestCase, lena, fromstring
class TestImage(PillowTestCase):
def test_sanity(self):
self.assertRaises(ValueError, lambda: lena().tobitmap())
lena().convert("1").tobitmap()
im1 = lena().convert("1")
bitmap = im1.tobitmap()
self.assertIsInstance(bitmap, bytes)
self.assert_image_equal(im1, fromstring(bitmap))
if __name__ == '__main__':
unittest.main()
# End of file