forked from pool/python-djvulibre
Update patches
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-djvulibre?expand=0&rev=45
This commit is contained in:
parent
c3f24f7f26
commit
bd23d775f0
@ -1,3 +1,11 @@
|
||||
-------------------------------------------------------------------
|
||||
Mon Jul 26 09:25:12 UTC 2021 - Matej Cepl <mcepl@suse.com>
|
||||
|
||||
- Port testing of the package to unittest, adding these patches:
|
||||
* remove-all-dependencies-on-nose-in-the-code.patch
|
||||
* remove-nose-in-documentation.patch
|
||||
* switch-to-src-project-layout-to-simplify-testing.patch
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Mar 8 13:48:17 UTC 2021 - Kyrill Detinov <lazy.kent@opensuse.org>
|
||||
|
||||
|
@ -27,10 +27,15 @@ URL: http://jwilk.net/software/python-djvulibre
|
||||
Source0: https://files.pythonhosted.org/packages/source/p/python-djvulibre/%{name}-%{version}.tar.gz
|
||||
Source1: https://files.pythonhosted.org/packages/source/p/python-djvulibre/%{name}-%{version}.tar.gz.asc
|
||||
Source2: %{name}.keyring
|
||||
# PATCH-FEATURE-UPSTREAM set of patches gh#jwilk/python-djvulibre#14 mcepl@suse.com
|
||||
# Set of patches to port testing to unittest
|
||||
Patch0: switch-to-src-project-layout-to-simplify-testing.patch
|
||||
Patch1: remove-all-dependencies-on-nose-in-the-code.patch
|
||||
Patch2: remove-nose-in-documentation.patch
|
||||
|
||||
BuildRequires: %{python_module Cython >= 0.19.1}
|
||||
BuildRequires: %{python_module Sphinx}
|
||||
BuildRequires: %{python_module devel}
|
||||
BuildRequires: %{python_module nose}
|
||||
BuildRequires: %{python_module setuptools}
|
||||
BuildRequires: djvulibre
|
||||
BuildRequires: fdupes
|
||||
@ -59,7 +64,8 @@ an open source implementation of DjVu.
|
||||
This package contains technical documentation.
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
%autosetup -p1
|
||||
|
||||
chmod -x examples/*
|
||||
|
||||
%build
|
||||
@ -74,8 +80,7 @@ rm build/sphinx/html/.buildinfo build/sphinx/html/objects.inv
|
||||
|
||||
%check
|
||||
cd tests/
|
||||
PYTHONPATH=%{buildroot}%{$python_sitearch}
|
||||
%python_expand PYTHONPATH=%{buildroot}%{$python_sitearch} $python -m nose --exclude='^test_export_ps$' --verbose
|
||||
%pyunittest_arch discover -v tests/
|
||||
|
||||
%files %{python_files}
|
||||
%license doc/COPYING
|
||||
|
2547
remove-all-dependencies-on-nose-in-the-code.patch
Normal file
2547
remove-all-dependencies-on-nose-in-the-code.patch
Normal file
File diff suppressed because it is too large
Load Diff
60
remove-nose-in-documentation.patch
Normal file
60
remove-nose-in-documentation.patch
Normal file
@ -0,0 +1,60 @@
|
||||
From 5bd3fff512681e1f8e071752b02039b85206fc4b Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Mat=C4=9Bj=20Cepl?= <mcepl@cepl.eu>
|
||||
Date: Mon, 26 Jul 2021 09:45:53 +0200
|
||||
Subject: [PATCH] Remove nose in documentation
|
||||
|
||||
---
|
||||
doc/README | 3 ---
|
||||
private/apt-install-build-reqs | 1 -
|
||||
private/build-and-test | 2 +-
|
||||
3 files changed, 1 insertion(+), 5 deletions(-)
|
||||
|
||||
diff --git a/doc/README b/doc/README
|
||||
index 76f2b63..c808cb2 100644
|
||||
--- a/doc/README
|
||||
+++ b/doc/README
|
||||
@@ -21,7 +21,6 @@ The following software is required to build python-djvulibre:
|
||||
|
||||
Additionally, the following software is needed to run the tests:
|
||||
|
||||
-* nose_
|
||||
* subprocess32_ (only for Python 2.X)
|
||||
* DjVuLibre_ command-line tools
|
||||
* Ghostscript_
|
||||
@@ -32,8 +31,6 @@ Additionally, the following software is needed to run the tests:
|
||||
https://cython.org/
|
||||
.. _pkg-config:
|
||||
https://wiki.freedesktop.org/www/Software/pkg-config/
|
||||
-.. _nose:
|
||||
- https://nose.readthedocs.io/
|
||||
.. _subprocess32:
|
||||
https://pypi.org/project/subprocess32/
|
||||
.. _Ghostscript:
|
||||
diff --git a/private/apt-install-build-reqs b/private/apt-install-build-reqs
|
||||
index 69beade..744ba5f 100755
|
||||
--- a/private/apt-install-build-reqs
|
||||
+++ b/private/apt-install-build-reqs
|
||||
@@ -21,7 +21,6 @@ python-dev
|
||||
cython
|
||||
'
|
||||
pkgs_tests='
|
||||
-python-nose
|
||||
python-subprocess32
|
||||
djvulibre-bin
|
||||
ghostscript
|
||||
diff --git a/private/build-and-test b/private/build-and-test
|
||||
index 08aa4fb..c86665b 100755
|
||||
--- a/private/build-and-test
|
||||
+++ b/private/build-and-test
|
||||
@@ -45,6 +45,6 @@ printf '%s\n' "$@" \
|
||||
| xargs -P"$opt_jobs" -t -I'{python}' env '{python}' setup.py build --build-lib 'build/{python}'
|
||||
cd tests
|
||||
printf '%s\n' "$@" \
|
||||
-| xargs -t -I'{python}' env PYTHONPATH="$PWD/../build/{python}" '{python}' -c 'import nose; nose.main()' --verbose
|
||||
+| xargs -t -I'{python}' env PYTHONPATH="$PWD/../build/{python}" '{python}' -c 'import unittest; unittest.main()' --verbose
|
||||
|
||||
# vim:ts=4 sts=4 sw=4 et
|
||||
--
|
||||
2.32.0
|
||||
|
||||
|
5602
switch-to-src-project-layout-to-simplify-testing.patch
Normal file
5602
switch-to-src-project-layout-to-simplify-testing.patch
Normal file
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user