mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-08-17 10:44:45 +03:00
Merge 7d129d4aca
into 766d3f4592
This commit is contained in:
commit
648df28545
|
@ -138,6 +138,16 @@ class TestNumpy(PillowTestCase):
|
|||
im.putdata(arr)
|
||||
self.assertEqual(len(im.getdata()), len(arr))
|
||||
|
||||
def test_no_resource_warning_for_numpy_array(self):
|
||||
# https://github.com/python-pillow/Pillow/issues/835
|
||||
# Arrange
|
||||
from numpy import array
|
||||
test_file = 'Tests/images/hopper.png'
|
||||
im = Image.open(test_file)
|
||||
|
||||
# Act/Assert
|
||||
self.assert_warning(None, lambda: array(im))
|
||||
|
||||
|
||||
def test_no_resource_warning_for_numpy_array(self):
|
||||
# https://github.com/python-pillow/Pillow/issues/835
|
||||
|
|
Loading…
Reference in New Issue
Block a user