Hello community,

here is the log from the commit of package python-pytest-html for 
openSUSE:Factory checked in at 2019-12-04 13:56:23
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-pytest-html (Old)
 and      /work/SRC/openSUSE:Factory/.python-pytest-html.new.4691 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-pytest-html"

Wed Dec  4 13:56:23 2019 rev:7 rq:753971 version:2.0.1

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-pytest-html/python-pytest-html.changes    
2019-09-26 20:37:54.087076757 +0200
+++ 
/work/SRC/openSUSE:Factory/.python-pytest-html.new.4691/python-pytest-html.changes
  2019-12-04 14:21:14.330481571 +0100
@@ -1,0 +2,8 @@
+Wed Dec  4 12:11:28 UTC 2019 - Tomáš Chvátal <tchva...@suse.com>
+
+- Update to 2.0.1:
+  * Properly check for presence of CSS file
+  * Added support for UTF-8 display
+  * Fix initial sort on column
+
+-------------------------------------------------------------------

Old:
----
  pytest-html-2.0.0.tar.gz

New:
----
  pytest-html-2.0.1.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-pytest-html.spec ++++++
--- /var/tmp/diff_new_pack.YBjdbN/_old  2019-12-04 14:21:14.706481888 +0100
+++ /var/tmp/diff_new_pack.YBjdbN/_new  2019-12-04 14:21:14.710481891 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package python-pytest-html
 #
-# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2019 SUSE LLC
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -19,11 +19,10 @@
 %{?!python_module:%define python_module() python-%{**} python3-%{**}}
 %define skip_python2 1
 Name:           python-pytest-html
-Version:        2.0.0
+Version:        2.0.1
 Release:        0
 Summary:        Pytest plugin for generating HTML reports
 License:        MPL-2.0
-Group:          Development/Languages/Python
 URL:            https://github.com/pytest-dev/pytest-html
 Source:         
https://files.pythonhosted.org/packages/source/p/pytest-html/pytest-html-%{version}.tar.gz
 BuildRequires:  %{python_module setuptools_scm}

++++++ pytest-html-2.0.0.tar.gz -> pytest-html-2.0.1.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/pytest-html-2.0.0/.travis.yml 
new/pytest-html-2.0.1/.travis.yml
--- old/pytest-html-2.0.0/.travis.yml   2019-09-09 16:43:56.000000000 +0200
+++ new/pytest-html-2.0.1/.travis.yml   2019-11-18 22:25:48.000000000 +0100
@@ -17,6 +17,7 @@
         directories:
           - $HOME/.cache/pre-commit
 
+    -
       python: 3.6
       env: TOXENV=py36
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/pytest-html-2.0.0/CHANGES.rst 
new/pytest-html-2.0.1/CHANGES.rst
--- old/pytest-html-2.0.0/CHANGES.rst   2019-09-09 16:43:56.000000000 +0200
+++ new/pytest-html-2.0.1/CHANGES.rst   2019-11-18 22:25:48.000000000 +0100
@@ -1,6 +1,20 @@
 Release Notes
 -------------
 
+**2.0.1 (2019-10-05)**
+
+* Properly check for presence of CSS file. (`#246 
<https://github.com/pytest-dev/pytest-html/issues/246>`_)
+
+    * Thanks to `@wanam <https://github.com/wanam>`_ for reporting, and 
`@krzysztof-pawlik-gat <https://github.com/krzysztof-pawlik-gat>`_ for the fix
+
+* Added support for UTF-8 display. (`#244 
<https://github.com/pytest-dev/pytest-html/pull/244>`_)
+
+    * Thanks to `@Izhu666 <https://github.com/lzhu666>`_ for the PR
+
+* Fix initial sort on column. (`#247 
<https://github.com/pytest-dev/pytest-html/issues/247>`_)
+
+    * Thanks to `@wanam <https://github.com/wanam>`_ for reporting and fixing
+
 **2.0.0 (2019-09-09)**
 
 * Drop support for Python 2.7. We will continue to accept patches to 
``1.22.x`` for the time being.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/pytest-html-2.0.0/PKG-INFO 
new/pytest-html-2.0.1/PKG-INFO
--- old/pytest-html-2.0.0/PKG-INFO      2019-09-09 16:44:19.000000000 +0200
+++ new/pytest-html-2.0.1/PKG-INFO      2019-11-18 22:26:15.000000000 +0100
@@ -1,6 +1,6 @@
 Metadata-Version: 1.2
 Name: pytest-html
-Version: 2.0.0
+Version: 2.0.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.0.0/pytest_html/plugin.py 
new/pytest-html-2.0.1/pytest_html/plugin.py
--- old/pytest-html-2.0.0/pytest_html/plugin.py 2019-09-09 16:43:56.000000000 
+0200
+++ new/pytest-html-2.0.1/pytest_html/plugin.py 2019-11-18 22:25:48.000000000 
+0100
@@ -68,7 +68,8 @@
     htmlpath = config.getoption("htmlpath")
     if htmlpath:
         for csspath in config.getoption("css"):
-            open(csspath)
+            if not os.path.exists(csspath):
+                raise IOError(f"No such file or directory: '{csspath}'")
         if not hasattr(config, "slaveinput"):
             # prevent opening htmlpath on slave nodes (xdist)
             config._html = HTMLReport(htmlpath, config)
@@ -103,7 +104,7 @@
 
     class TestResult:
         def __init__(self, outcome, report, logfile, config):
-            self.test_id = report.nodeid
+            self.test_id = 
report.nodeid.encode("utf-8").decode("unicode_escape")
             if getattr(report, "when", "call") != "call":
                 self.test_id = "::".join([report.nodeid, report.when])
             self.time = getattr(report, "duration", 0.0)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/pytest-html-2.0.0/pytest_html/resources/main.js 
new/pytest-html-2.0.1/pytest_html/resources/main.js
--- old/pytest-html-2.0.0/pytest_html/resources/main.js 2019-09-09 
16:43:56.000000000 +0200
+++ new/pytest-html-2.0.1/pytest_html/resources/main.js 2019-11-18 
22:25:48.000000000 +0100
@@ -111,7 +111,7 @@
 
     show_filters();
 
-    toggle_sort_states(find('.initial-sort'));
+    sort_column(find('.initial-sort'));
 
     find_all('.sortable').forEach(function(elem) {
         elem.addEventListener("click",
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/pytest-html-2.0.0/pytest_html/resources/style.css 
new/pytest-html-2.0.1/pytest_html/resources/style.css
--- old/pytest-html-2.0.0/pytest_html/resources/style.css       2019-09-09 
16:43:56.000000000 +0200
+++ new/pytest-html-2.0.1/pytest_html/resources/style.css       2019-11-18 
22:25:48.000000000 +0100
@@ -1,7 +1,8 @@
 body {
        font-family: Helvetica, Arial, sans-serif;
        font-size: 12px;
-       min-width: 1200px;
+       /* do not increase min-width as some may use split screens */
+       min-width: 800px;
        color: #999;
 }
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/pytest-html-2.0.0/pytest_html.egg-info/PKG-INFO 
new/pytest-html-2.0.1/pytest_html.egg-info/PKG-INFO
--- old/pytest-html-2.0.0/pytest_html.egg-info/PKG-INFO 2019-09-09 
16:44:19.000000000 +0200
+++ new/pytest-html-2.0.1/pytest_html.egg-info/PKG-INFO 2019-11-18 
22:26:14.000000000 +0100
@@ -1,6 +1,6 @@
 Metadata-Version: 1.2
 Name: pytest-html
-Version: 2.0.0
+Version: 2.0.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.0.0/testing/test_pytest_html.py 
new/pytest-html-2.0.1/testing/test_pytest_html.py
--- old/pytest-html-2.0.0/testing/test_pytest_html.py   2019-09-09 
16:43:56.000000000 +0200
+++ new/pytest-html-2.0.1/testing/test_pytest_html.py   2019-11-18 
22:25:48.000000000 +0100
@@ -759,7 +759,7 @@
         assert re.search(regex_error, html) is not None
 
     @pytest.mark.parametrize("colors", [(["red"]), (["green", "blue"])])
-    def test_css(self, testdir, colors):
+    def test_css(self, testdir, recwarn, colors):
         testdir.makepyfile("def test_pass(): pass")
         css = {}
         cssargs = []
@@ -770,17 +770,32 @@
             cssargs.extend(["--css", path])
         result, html = run(testdir, "report.html", "--self-contained-html", 
*cssargs)
         assert result.ret == 0
+        assert len(recwarn) == 0
         for k, v in css.items():
             assert str(v["path"]) in html
             assert v["style"] in html
 
-    def test_css_invalid(self, testdir):
+    def test_css_invalid(self, testdir, recwarn):
         testdir.makepyfile("def test_pass(): pass")
         result = testdir.runpytest("--html", "report.html", "--css", 
"style.css")
         assert result.ret
+        assert len(recwarn) == 0
         assert "No such file or directory: 'style.css'" in result.stderr.str()
 
     def test_css_invalid_no_html(self, testdir):
         testdir.makepyfile("def test_pass(): pass")
         result = testdir.runpytest("--css", "style.css")
         assert result.ret == 0
+
+    def test_report_display_utf8(self, testdir):
+        testdir.makepyfile(
+            """
+            import pytest
+            @pytest.mark.parametrize("utf8", [("测试用例名称")])
+            def test_pass(utf8):
+                assert True
+        """
+        )
+        result, html = run(testdir)
+        assert result.ret == 0
+        assert r"\u6d4b\u8bd5\u7528\u4f8b\u540d\u79f0" not in html


Reply via email to