Package: pillow / 4.0.0-4

generate-webp-file Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
Index: b/Tests/test_file_webp.py
===================================================================
--- a/Tests/test_file_webp.py
+++ b/Tests/test_file_webp.py
@@ -1,6 +1,7 @@
 from helper import unittest, PillowTestCase, hopper
 
 from PIL import Image
+import os
 
 try:
     from PIL import _webp
@@ -34,7 +35,10 @@ class TestFileWebp(PillowTestCase):
 
         # generated with:
         # dwebp -ppm ../../Tests/images/hopper.webp -o hopper_webp_bits.ppm
-        target = Image.open('Tests/images/hopper_webp_bits.ppm')
+        if 'ADTTMP' in os.environ:
+            target = Image.open(os.path.join(os.environ['ADTTMP'], 'hopper_webp.ppm'))
+        else:
+            target = Image.open('Tests/images/hopper_webp_bits.ppm')
         self.assert_image_similar(image, target, 20.0)
 
     def test_write_rgb(self):