Hello community,
here is the log from the commit of package python-html5lib for openSUSE:Factory
checked in at 2020-06-05 19:59:27
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-html5lib (Old)
and /work/SRC/openSUSE:Factory/.python-html5lib.new.3606 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-html5lib"
Fri Jun 5 19:59:27 2020 rev:21 rq:810160 version:1.0.1
Changes:
--------
--- /work/SRC/openSUSE:Factory/python-html5lib/python-html5lib.changes
2020-05-08 23:02:22.657497725 +0200
+++
/work/SRC/openSUSE:Factory/.python-html5lib.new.3606/python-html5lib.changes
2020-06-05 19:59:30.779793152 +0200
@@ -1,0 +2,6 @@
+Fri May 29 09:17:23 UTC 2020 - Tomáš Chvátal <[email protected]>
+
+- Add patch to fix run with pytest5:
+ * pytest5.patch
+
+-------------------------------------------------------------------
New:
----
pytest5.patch
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-html5lib.spec ++++++
--- /var/tmp/diff_new_pack.PKGles/_old 2020-06-05 19:59:31.403795310 +0200
+++ /var/tmp/diff_new_pack.PKGles/_new 2020-06-05 19:59:31.407795324 +0200
@@ -28,11 +28,12 @@
# This patch makes testsuite pass with pytest4
Patch0: pytest4-mhroncok.patch
Patch1: collections-abc.patch
+Patch2: pytest5.patch
BuildRequires: %{python_module Genshi}
BuildRequires: %{python_module datrie}
BuildRequires: %{python_module lxml}
BuildRequires: %{python_module mock}
-BuildRequires: %{python_module pytest < 5.0}
+BuildRequires: %{python_module pytest >= 4.0}
BuildRequires: %{python_module pytest-expect}
BuildRequires: %{python_module setuptools >= 18.5}
BuildRequires: %{python_module six >= 1.9}
++++++ pytest5.patch ++++++
>From 3f10121d98ce8ca36b4b856275093dd189fdf1d2 Mon Sep 17 00:00:00 2001
From: Sam Sneddon <[email protected]>
Date: Fri, 22 May 2020 20:37:19 +0100
Subject: [PATCH] Update pytest
---
.pytest.expect | 4 +--
html5lib/tests/tree_construction.py | 12 ++++-----
3 files changed, 15 insertions(+), 42 deletions(-)
diff --git a/html5lib/tests/tree_construction.py
b/html5lib/tests/tree_construction.py
index 6112d11d..1ef6e725 100644
--- a/html5lib/tests/tree_construction.py
+++ b/html5lib/tests/tree_construction.py
@@ -57,8 +57,6 @@ def _getParserTests(self, treeName, treeAPIs):
item.add_marker(pytest.mark.parser)
if namespaceHTMLElements:
item.add_marker(pytest.mark.namespaced)
- if treeAPIs is None:
- item.add_marker(pytest.mark.skipif(True, reason="Treebuilder
not loaded"))
yield item
def _getTreeWalkerTests(self, treeName, treeAPIs):
@@ -69,8 +67,6 @@ def _getTreeWalkerTests(self, treeName, treeAPIs):
treeAPIs)
item.add_marker(getattr(pytest.mark, treeName))
item.add_marker(pytest.mark.treewalker)
- if treeAPIs is None:
- item.add_marker(pytest.mark.skipif(True, reason="Treebuilder not
loaded"))
yield item
@@ -84,12 +80,14 @@ def convertTreeDump(data):
class ParserTest(pytest.Item):
def __init__(self, name, parent, test, treeClass, namespaceHTMLElements):
super(ParserTest, self).__init__(name, parent)
- self.obj = lambda: 1 # this is to hack around skipif needing a
function!
self.test = test
self.treeClass = treeClass
self.namespaceHTMLElements = namespaceHTMLElements
def runtest(self):
+ if self.treeClass is None:
+ pytest.skip("Treebuilder not loaded")
+
p = html5parser.HTMLParser(tree=self.treeClass,
namespaceHTMLElements=self.namespaceHTMLElements)
@@ -147,11 +145,13 @@ def repr_failure(self, excinfo):
class TreeWalkerTest(pytest.Item):
def __init__(self, name, parent, test, treeAPIs):
super(TreeWalkerTest, self).__init__(name, parent)
- self.obj = lambda: 1 # this is to hack around skipif needing a
function!
self.test = test
self.treeAPIs = treeAPIs
def runtest(self):
+ if self.treeAPIs is None:
+ pytest.skip("Treebuilder not loaded")
+
p = html5parser.HTMLParser(tree=self.treeAPIs["builder"])
input = self.test['data']