Hello community, here is the log from the commit of package python-pytest-subtests for openSUSE:Factory checked in at 2020-11-05 21:56:06 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/python-pytest-subtests (Old) and /work/SRC/openSUSE:Factory/.python-pytest-subtests.new.11331 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-pytest-subtests" Thu Nov 5 21:56:06 2020 rev:4 rq:846267 version:0.3.2 Changes: -------- --- /work/SRC/openSUSE:Factory/python-pytest-subtests/python-pytest-subtests.changes 2020-06-10 00:49:13.927073062 +0200 +++ /work/SRC/openSUSE:Factory/.python-pytest-subtests.new.11331/python-pytest-subtests.changes 2020-11-05 21:56:37.647953832 +0100 @@ -1,0 +2,6 @@ +Thu Nov 5 15:02:17 UTC 2020 - Marketa Machova <mmach...@suse.com> + +- Update to 0.3.2 + * Fix pytest 6.0 support. + +------------------------------------------------------------------- Old: ---- pytest-subtests-0.3.1.tar.gz New: ---- pytest-subtests-0.3.2.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-pytest-subtests.spec ++++++ --- /var/tmp/diff_new_pack.zdzP4P/_old 2020-11-05 21:56:38.099952815 +0100 +++ /var/tmp/diff_new_pack.zdzP4P/_new 2020-11-05 21:56:38.103952807 +0100 @@ -19,7 +19,7 @@ %{?!python_module:%define python_module() python-%{**} python3-%{**}} %define skip_python2 1 Name: python-pytest-subtests -Version: 0.3.1 +Version: 0.3.2 Release: 0 Summary: Python unittest subTest() support and subtests fixture License: MIT ++++++ pytest-subtests-0.3.1.tar.gz -> pytest-subtests-0.3.2.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pytest-subtests-0.3.1/.github/workflows/main.yml new/pytest-subtests-0.3.2/.github/workflows/main.yml --- old/pytest-subtests-0.3.1/.github/workflows/main.yml 2020-05-20 22:42:14.000000000 +0200 +++ new/pytest-subtests-0.3.2/.github/workflows/main.yml 2020-08-01 17:00:34.000000000 +0200 @@ -68,6 +68,10 @@ python: "3.8" os: ubuntu-latest tox_env: "py38-pytest53" + - name: "ubuntu-py38-pytest54" + python: "3.8" + os: ubuntu-latest + tox_env: "py38-pytest54" - name: "linting" python: "3.7" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pytest-subtests-0.3.1/CHANGELOG.rst new/pytest-subtests-0.3.2/CHANGELOG.rst --- old/pytest-subtests-0.3.1/CHANGELOG.rst 2020-05-20 22:42:14.000000000 +0200 +++ new/pytest-subtests-0.3.2/CHANGELOG.rst 2020-08-01 17:00:34.000000000 +0200 @@ -1,6 +1,11 @@ CHANGELOG ========= +0.3.2 (2020-08-01) +------------------ + +* Fix pytest 6.0 support. + 0.3.1 (2020-05-20) ------------------ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pytest-subtests-0.3.1/PKG-INFO new/pytest-subtests-0.3.2/PKG-INFO --- old/pytest-subtests-0.3.1/PKG-INFO 2020-05-20 22:42:20.000000000 +0200 +++ new/pytest-subtests-0.3.2/PKG-INFO 2020-08-01 17:00:45.000000000 +0200 @@ -1,6 +1,6 @@ Metadata-Version: 1.2 Name: pytest-subtests -Version: 0.3.1 +Version: 0.3.2 Summary: unittest subTest() support and subtests fixture Home-page: https://github.com/pytest-dev/pytest-subtests Author: Bruno Oliveira diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pytest-subtests-0.3.1/pytest_subtests.egg-info/PKG-INFO new/pytest-subtests-0.3.2/pytest_subtests.egg-info/PKG-INFO --- old/pytest-subtests-0.3.1/pytest_subtests.egg-info/PKG-INFO 2020-05-20 22:42:20.000000000 +0200 +++ new/pytest-subtests-0.3.2/pytest_subtests.egg-info/PKG-INFO 2020-08-01 17:00:44.000000000 +0200 @@ -1,6 +1,6 @@ Metadata-Version: 1.2 Name: pytest-subtests -Version: 0.3.1 +Version: 0.3.2 Summary: unittest subTest() support and subtests fixture Home-page: https://github.com/pytest-dev/pytest-subtests Author: Bruno Oliveira diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pytest-subtests-0.3.1/pytest_subtests.py new/pytest-subtests-0.3.2/pytest_subtests.py --- old/pytest-subtests-0.3.1/pytest_subtests.py 2020-05-20 22:42:14.000000000 +0200 +++ new/pytest-subtests-0.3.2/pytest_subtests.py 2020-08-01 17:00:34.000000000 +0200 @@ -1,6 +1,6 @@ import sys +import time from contextlib import contextmanager -from time import monotonic import attr import pytest @@ -74,7 +74,9 @@ def _addSubTest(self, test_case, test, exc_info): if exc_info is not None: msg = test._message if isinstance(test._message, str) else None - call_info = CallInfo(None, ExceptionInfo(exc_info), 0, 0, when="call") + call_info = make_call_info( + ExceptionInfo(exc_info), start=0, stop=0, duration=0, when="call" + ) sub_report = SubTestReport.from_item_and_call(item=self, call=call_info) sub_report.context = SubTestContext(msg, dict(test.params)) self.ihook.pytest_runtest_logreport(report=sub_report) @@ -147,7 +149,8 @@ @contextmanager def test(self, msg=None, **kwargs): - start = monotonic() + start = time.time() + precise_start = time.perf_counter() exc_info = None with self._capturing_output() as captured: @@ -156,9 +159,13 @@ except (Exception, OutcomeException): exc_info = ExceptionInfo.from_current() - stop = monotonic() + precise_stop = time.perf_counter() + duration = precise_stop - precise_start + stop = time.time() - call_info = CallInfo(None, exc_info, start, stop, when="call") + call_info = make_call_info( + exc_info, start=start, stop=stop, duration=duration, when="call" + ) sub_report = SubTestReport.from_item_and_call(item=self.item, call=call_info) sub_report.context = SubTestContext(msg, kwargs.copy()) @@ -168,6 +175,16 @@ self.ihook.pytest_runtest_logreport(report=sub_report) +def make_call_info(exc_info, *, start, stop, duration, when): + try: + return CallInfo( + None, exc_info, start=start, stop=stop, duration=duration, when=when + ) + except TypeError: + # support for pytest<6: didn't have a duration parameter then + return CallInfo(None, exc_info, start=start, stop=stop, when=when) + + @attr.s class Captured: out = attr.ib(default="", type=str) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pytest-subtests-0.3.1/tox.ini new/pytest-subtests-0.3.2/tox.ini --- old/pytest-subtests-0.3.1/tox.ini 2020-05-20 22:42:14.000000000 +0200 +++ new/pytest-subtests-0.3.2/tox.ini 2020-08-01 17:00:34.000000000 +0200 @@ -1,11 +1,12 @@ [tox] -envlist = py35,py36,py37,py38,py38-pytest53,pypy3,linting +envlist = py35,py36,py37,py38,py38-pytest53,py38-pytest54,pypy3,linting [testenv] passenv = USER USERNAME TRAVIS PYTEST_ADDOPTS deps = pytest-xdist>=1.28 pytest53: pytest ==5.3.5 + pytest54: pytest ==5.4.3 commands = pytest {posargs:tests}