From 50bfb12c27643dea1cadcfa17ceb55ea381704d84a9127f3f7c25325c2075f49 Mon Sep 17 00:00:00 2001 From: Daniel Garcia Date: Fri, 2 Dec 2022 09:55:56 +0000 Subject: [PATCH] - Add fix-tests.patch gh#mgedmin/restview@5033eacb1d55 - Remove python_module macro definition - More specific python_sitelib in %files - Use autosetup instead of setup + autopatch OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-restview?expand=0&rev=13 --- fix-tests.patch | 90 +++++++++++++++++++++++++++++++++++++++++ python-restview.changes | 8 ++++ python-restview.spec | 9 +++-- 3 files changed, 103 insertions(+), 4 deletions(-) create mode 100644 fix-tests.patch diff --git a/fix-tests.patch b/fix-tests.patch new file mode 100644 index 0000000..7508573 --- /dev/null +++ b/fix-tests.patch @@ -0,0 +1,90 @@ +diff --git a/src/restview/tests.py b/src/restview/tests.py +index 71aeb77..c840cb8 100644 +--- a/src/restview/tests.py ++++ b/src/restview/tests.py +@@ -541,10 +541,9 @@ def doctest_RestViewer_rest_to_html(): + ... ''', settings={'cloak_email_addresses': True}).strip()) + ... # doctest: +ELLIPSIS,+REPORT_NDIFF + +- ++ + + +- + ... + example + + + +-
++
+

example

+ +

This is a doctest:

+@@ -570,11 +569,9 @@ def doctest_RestViewer_rest_to_html(): +

This is a reference: README.rst

+

This is an email: marius@gedmin.as

+

This is a literal block:

+-
+-        See CHANGES.rst, mkay?
+-        
++
See CHANGES.rst, mkay?
+

This is an inline literal: README.txt.

+-
++ + + + +@@ -594,10 +591,7 @@ def doctest_RestViewer_rest_to_html_css_url(): + ... ''').strip()) + ... # doctest: +ELLIPSIS,+REPORT_NDIFF + +- +- +- +- ++ + ... + ... + +@@ -606,11 +600,11 @@ def doctest_RestViewer_rest_to_html_css_url(): + + + +-
++
+ + +

Some text

+-
++ + + + +@@ -729,21 +723,18 @@ def doctest_RestViewer_rest_to_html_pypi_strict(): + ... ''').strip().replace(""", '"')) + ... # doctest: +ELLIPSIS,+REPORT_NDIFF + +- +- +- +- ++ + ... + Hello +