Hello community, here is the log from the commit of package python-pytest-html for openSUSE:Factory checked in at 2020-03-23 12:52:10 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/python-pytest-html (Old) and /work/SRC/openSUSE:Factory/.python-pytest-html.new.3160 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-pytest-html" Mon Mar 23 12:52:10 2020 rev:10 rq:787378 version:2.1.1 Changes: -------- --- /work/SRC/openSUSE:Factory/python-pytest-html/python-pytest-html.changes 2020-03-19 19:51:20.932220461 +0100 +++ /work/SRC/openSUSE:Factory/.python-pytest-html.new.3160/python-pytest-html.changes 2020-03-23 12:53:16.308058570 +0100 @@ -1,0 +2,6 @@ +Mon Mar 23 09:08:07 UTC 2020 - Tomáš Chvátal <[email protected]> + +- Update to 2.1.1: + * Fix issue with funcargs causing failures. (#282) + +------------------------------------------------------------------- Old: ---- pytest-html-2.1.0.tar.gz New: ---- pytest-html-2.1.1.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-pytest-html.spec ++++++ --- /var/tmp/diff_new_pack.MK1VyU/_old 2020-03-23 12:53:16.844058907 +0100 +++ /var/tmp/diff_new_pack.MK1VyU/_new 2020-03-23 12:53:16.848058909 +0100 @@ -19,7 +19,7 @@ %{?!python_module:%define python_module() python-%{**} python3-%{**}} %define skip_python2 1 Name: python-pytest-html -Version: 2.1.0 +Version: 2.1.1 Release: 0 Summary: Pytest plugin for generating HTML reports License: MPL-2.0 ++++++ pytest-html-2.1.0.tar.gz -> pytest-html-2.1.1.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pytest-html-2.1.0/CHANGES.rst new/pytest-html-2.1.1/CHANGES.rst --- old/pytest-html-2.1.0/CHANGES.rst 2020-03-11 13:38:36.000000000 +0100 +++ new/pytest-html-2.1.1/CHANGES.rst 2020-03-19 12:14:05.000000000 +0100 @@ -1,6 +1,12 @@ Release Notes ------------- +**2.1.1 (2020-03-18)** + +* Fix issue with funcargs causing failures. (`#282 <https://github.com/pytest-dev/pytest-html/issues/282>`_) + + * Thanks to `@ssbarnea <https://github.com/ssbarnea>`_ for reporting and `@christiansandberg <https://github.com/christiansandberg>`_ for the fix + **2.1.0 (2020-03-09)** * Added support for MP4 video format. (`#260 <https://github.com/pytest-dev/pytest-html/pull/260>`_) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pytest-html-2.1.0/PKG-INFO new/pytest-html-2.1.1/PKG-INFO --- old/pytest-html-2.1.0/PKG-INFO 2020-03-11 13:38:57.000000000 +0100 +++ new/pytest-html-2.1.1/PKG-INFO 2020-03-19 12:14:27.000000000 +0100 @@ -1,6 +1,6 @@ Metadata-Version: 1.2 Name: pytest-html -Version: 2.1.0 +Version: 2.1.1 Summary: pytest plugin for generating HTML reports Home-page: https://github.com/pytest-dev/pytest-html Author: Dave Hunt diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pytest-html-2.1.0/pytest_html/plugin.py new/pytest-html-2.1.1/pytest_html/plugin.py --- old/pytest-html-2.1.0/pytest_html/plugin.py 2020-03-11 13:38:36.000000000 +0100 +++ new/pytest-html-2.1.1/pytest_html/plugin.py 2020-03-19 12:14:05.000000000 +0100 @@ -95,13 +95,13 @@ outcome = yield report = outcome.get_result() if report.when == "call": - fixture_extras = item.funcargs.get("extra", []) + fixture_extras = getattr(item.config, "extras", []) plugin_extras = getattr(report, "extra", []) report.extra = fixture_extras + plugin_extras @pytest.fixture -def extra(): +def extra(pytestconfig): """Add details to the HTML reports. .. code-block:: python @@ -110,7 +110,9 @@ def test_foo(extra): extra.append(pytest_html.extras.url('http://www.example.com/')) """ - return [] + pytestconfig.extras = [] + yield pytestconfig.extras + del pytestconfig.extras[:] def data_uri(content, mime_type="text/plain", charset="utf-8"): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pytest-html-2.1.0/pytest_html.egg-info/PKG-INFO new/pytest-html-2.1.1/pytest_html.egg-info/PKG-INFO --- old/pytest-html-2.1.0/pytest_html.egg-info/PKG-INFO 2020-03-11 13:38:57.000000000 +0100 +++ new/pytest-html-2.1.1/pytest_html.egg-info/PKG-INFO 2020-03-19 12:14:27.000000000 +0100 @@ -1,6 +1,6 @@ Metadata-Version: 1.2 Name: pytest-html -Version: 2.1.0 +Version: 2.1.1 Summary: pytest plugin for generating HTML reports Home-page: https://github.com/pytest-dev/pytest-html Author: Dave Hunt diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pytest-html-2.1.0/testing/test_pytest_html.py new/pytest-html-2.1.1/testing/test_pytest_html.py --- old/pytest-html-2.1.0/testing/test_pytest_html.py 2020-03-11 13:38:36.000000000 +0100 +++ new/pytest-html-2.1.1/testing/test_pytest_html.py 2020-03-19 12:14:05.000000000 +0100 @@ -14,7 +14,20 @@ pytest_plugins = ("pytester",) +def handle_tr_writer_deprecation(): + # Remove this function when they've fixed + # https://github.com/pytest-dev/pytest/issues/6936 + import warnings + from _pytest.warnings import _setoption + + arg = "ignore:TerminalReporter.writer:pytest.PytestDeprecationWarning" + _setoption(warnings, arg) + + def run(testdir, path="report.html", *args): + # TODO: Temporary hack until they fix + # https://github.com/pytest-dev/pytest/issues/6936 + handle_tr_writer_deprecation() # TODO: Temporary hack path = testdir.tmpdir.join(path) result = testdir.runpytest("--html", path, *args) return result, read_html(path) @@ -219,6 +232,9 @@ assert report_title in html def test_report_title_addopts_env_var(self, testdir, monkeypatch): + # TODO: Temporary hack until they fix + # https://github.com/pytest-dev/pytest/issues/6936 + handle_tr_writer_deprecation() report_location = "REPORT_LOCATION" report_name = "MuhReport" monkeypatch.setenv(report_location, report_name) @@ -878,6 +894,9 @@ assert "No such file or directory: 'style.css'" in result.stderr.str() def test_css_invalid_no_html(self, testdir): + # TODO: Temporary hack until they fix + # https://github.com/pytest-dev/pytest/issues/6936 + handle_tr_writer_deprecation() testdir.makepyfile("def test_pass(): pass") result = testdir.runpytest("--css", "style.css") assert result.ret == 0
