Replace lena.tar with hopper.tar

This commit is contained in:
hugovk 2014-09-04 12:21:19 +03:00
parent 06a2378f52
commit 14ac9ce59c
3 changed files with 4 additions and 4 deletions

BIN
Tests/images/hopper.tar Normal file

Binary file not shown.

Binary file not shown.

View File

@ -4,8 +4,8 @@ from PIL import Image, TarIO
codecs = dir(Image.core) codecs = dir(Image.core)
# sample ppm stream # Sample tar archive
tarfile = "Tests/images/lena.tar" TEST_TAR_FILE = "Tests/images/hopper.tar"
class TestFileTar(PillowTestCase): class TestFileTar(PillowTestCase):
@ -16,7 +16,7 @@ class TestFileTar(PillowTestCase):
def test_sanity(self): def test_sanity(self):
if "zip_decoder" in codecs: if "zip_decoder" in codecs:
tar = TarIO.TarIO(tarfile, 'lena.png') tar = TarIO.TarIO(TEST_TAR_FILE, 'hopper.png')
im = Image.open(tar) im = Image.open(tar)
im.load() im.load()
self.assertEqual(im.mode, "RGB") self.assertEqual(im.mode, "RGB")
@ -24,7 +24,7 @@ class TestFileTar(PillowTestCase):
self.assertEqual(im.format, "PNG") self.assertEqual(im.format, "PNG")
if "jpeg_decoder" in codecs: if "jpeg_decoder" in codecs:
tar = TarIO.TarIO(tarfile, 'lena.jpg') tar = TarIO.TarIO(TEST_TAR_FILE, 'hopper.jpg')
im = Image.open(tar) im = Image.open(tar)
im.load() im.load()
self.assertEqual(im.mode, "RGB") self.assertEqual(im.mode, "RGB")