mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-08-05 21:10:11 +03:00
💄
This commit is contained in:
parent
2f6467c94e
commit
b471158498
|
@ -22,7 +22,6 @@ def test_sanity():
|
||||||
|
|
||||||
def test_large_file_is_truncated():
|
def test_large_file_is_truncated():
|
||||||
import warnings
|
import warnings
|
||||||
from unittest.mock import patch
|
|
||||||
|
|
||||||
try:
|
try:
|
||||||
original_value = GimpPaletteFile._max_file_size
|
original_value = GimpPaletteFile._max_file_size
|
||||||
|
@ -31,7 +30,7 @@ def test_large_file_is_truncated():
|
||||||
warnings.simplefilter("error")
|
warnings.simplefilter("error")
|
||||||
with pytest.raises(UserWarning):
|
with pytest.raises(UserWarning):
|
||||||
with open("Tests/images/custom_gimp_palette.gpl", "rb") as fp:
|
with open("Tests/images/custom_gimp_palette.gpl", "rb") as fp:
|
||||||
palette_file = GimpPaletteFile(fp)
|
GimpPaletteFile(fp)
|
||||||
|
|
||||||
finally:
|
finally:
|
||||||
GimpPaletteFile._max_file_size = original_value
|
GimpPaletteFile._max_file_size = original_value
|
||||||
|
|
Loading…
Reference in New Issue
Block a user