forked from pool/python-pilkit
Accepting request 967322 from home:pgajdos:python
- do not require python-mock for build - added patches fix https://github.com/matthewwithanm/pilkit/issues/54 + python-pilkit-no-mock.patch OBS-URL: https://build.opensuse.org/request/show/967322 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pilkit?expand=0&rev=11
This commit is contained in:
26
python-pilkit-no-mock.patch
Normal file
26
python-pilkit-no-mock.patch
Normal file
@@ -0,0 +1,26 @@
|
||||
Index: pilkit-2.0/tests/test_processors.py
|
||||
===================================================================
|
||||
--- pilkit-2.0.orig/tests/test_processors.py
|
||||
+++ pilkit-2.0/tests/test_processors.py
|
||||
@@ -4,7 +4,7 @@ from pilkit.processors import (Resize, R
|
||||
import os
|
||||
from pilkit.processors.resize import Thumbnail
|
||||
from .utils import create_image, eq_, assert_true
|
||||
-import mock
|
||||
+import unittest.mock as mock
|
||||
|
||||
|
||||
def test_smartcrop():
|
||||
Index: pilkit-2.0/tests/test_utils.py
|
||||
===================================================================
|
||||
--- pilkit-2.0.orig/tests/test_utils.py
|
||||
+++ pilkit-2.0/tests/test_utils.py
|
||||
@@ -5,7 +5,7 @@ from pilkit.lib import Image
|
||||
from pilkit.utils import (extension_to_format, format_to_extension, FileWrapper,
|
||||
save_image, prepare_image, quiet)
|
||||
from pytest import raises
|
||||
-from mock import Mock, patch
|
||||
+from unittest.mock import Mock, patch
|
||||
from tempfile import NamedTemporaryFile
|
||||
from .utils import create_image, eq_, assert_true
|
||||
|
Reference in New Issue
Block a user