String attr test case

This commit is contained in:
wiredfool 2013-10-22 10:09:25 -07:00
parent 758da6c581
commit 6357b4707c

View File

@ -93,6 +93,8 @@ def test_g4_write():
_assert_noerr(reread)
assert_image_equal(reread, rot)
assert_equal(reread.info['compression'], orig.info['compression'])
assert_false(orig.tobytes() == reread.tobytes())
def test_adobe_deflate_tiff():
@ -153,3 +155,17 @@ def test_big_endian():
assert_equal(reread.info['compression'], im.info['compression'])
assert_equal(reread.getpixel((0,0)), 480)
def test_g4_string_info():
"""Tests String data in info directory"""
file = "Tests/images/lena_g4_500.tif"
orig = Image.open(file)
out = tempfile("temp.tif")
orig.tag[269] = 'temp.tif'
orig.save(out)
reread = Image.open(out)
assert_equal('temp.tif', reread.tag[269])