py3k: FIX: TGA missing o8 declaration

Plus, TGA was eligible for a round-trip test in test_imagefile. It has one
now.
This commit is contained in:
Brian Crowell 2012-10-23 21:58:15 -05:00 committed by Shuge Lee
parent d6c6dd4a88
commit 825718a76a
2 changed files with 2 additions and 0 deletions

View File

@ -133,6 +133,7 @@ class TgaImageFile(ImageFile.ImageFile):
# --------------------------------------------------------------------
# Write TGA file
o8 = _binary.o8
o16 = _binary.o16le
o32 = _binary.o32le

View File

@ -40,6 +40,7 @@ def test_parser():
assert_image_equal(*roundtrip("PPM"))
assert_image_equal(*roundtrip("TIFF"))
assert_image_equal(*roundtrip("XBM"))
assert_image_equal(*roundtrip("TGA"))
im1, im2 = roundtrip("JPEG") # lossy compression
assert_image(im1, im2.mode, im2.size)