Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package python-pytest-subtests for
openSUSE:Factory checked in at 2021-04-01 14:16:51
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-pytest-subtests (Old)
and /work/SRC/openSUSE:Factory/.python-pytest-subtests.new.2401 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-pytest-subtests"
Thu Apr 1 14:16:51 2021 rev:5 rq:881274 version:0.4.0
Changes:
--------
---
/work/SRC/openSUSE:Factory/python-pytest-subtests/python-pytest-subtests.changes
2020-11-05 21:56:37.647953832 +0100
+++
/work/SRC/openSUSE:Factory/.python-pytest-subtests.new.2401/python-pytest-subtests.changes
2021-04-01 14:18:03.352049549 +0200
@@ -1,0 +2,7 @@
+Sat Mar 20 20:03:28 UTC 2021 - Ben Greiner <[email protected]>
+
+- Update to 0.4.0
+ * Add Python 3.9 support and bump pytest requirement
+ * Add support for --pdb
+
+-------------------------------------------------------------------
Old:
----
pytest-subtests-0.3.2.tar.gz
New:
----
pytest-subtests-0.4.0.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-pytest-subtests.spec ++++++
--- /var/tmp/diff_new_pack.3FtfSk/_old 2021-04-01 14:18:03.828050290 +0200
+++ /var/tmp/diff_new_pack.3FtfSk/_new 2021-04-01 14:18:03.832050296 +0200
@@ -1,7 +1,7 @@
#
# spec file for package python-pytest-subtests
#
-# Copyright (c) 2020 SUSE LLC
+# Copyright (c) 2021 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -19,7 +19,7 @@
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%define skip_python2 1
Name: python-pytest-subtests
-Version: 0.3.2
+Version: 0.4.0
Release: 0
Summary: Python unittest subTest() support and subtests fixture
License: MIT
@@ -29,10 +29,10 @@
BuildRequires: %{python_module setuptools_scm}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
-Requires: python-pytest >= 4.4.0
+Requires: python-pytest >= 5.3.0
BuildArch: noarch
# SECTION test requirements
-BuildRequires: %{python_module pytest >= 4.4.0}
+BuildRequires: %{python_module pytest >= 5.3.0}
# /SECTION
%python_subpackages
@@ -55,6 +55,8 @@
%files %{python_files}
%doc CHANGELOG.rst README.rst
%license LICENSE
-%{python_sitelib}/*
+%{python_sitelib}/pytest_subtests.py*
+%pycache_only %{python_sitelib}/__pycache__/pytest_subtests*.pyc
+%{python_sitelib}/pytest_subtests-%{version}*-info
%changelog
++++++ pytest-subtests-0.3.2.tar.gz -> pytest-subtests-0.4.0.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/pytest-subtests-0.3.2/.github/workflows/main.yml
new/pytest-subtests-0.4.0/.github/workflows/main.yml
--- old/pytest-subtests-0.3.2/.github/workflows/main.yml 2020-08-01
17:00:34.000000000 +0200
+++ new/pytest-subtests-0.4.0/.github/workflows/main.yml 2020-12-13
14:33:05.000000000 +0100
@@ -15,12 +15,14 @@
"windows-py36",
"windows-py37",
"windows-py38",
+ "windows-py39",
"windows-py38-pytest53",
"ubuntu-py35",
"ubuntu-py36",
"ubuntu-py37",
"ubuntu-py38",
+ "ubuntu-py39",
"ubuntu-py38-pytest53",
"linting",
@@ -43,10 +45,18 @@
python: "3.8"
os: windows-latest
tox_env: "py38"
+ - name: "windows-py39"
+ python: "3.9"
+ os: windows-latest
+ tox_env: "py39"
- name: "windows-py38-pytest53"
python: "3.8"
os: windows-latest
tox_env: "py38-pytest53"
+ - name: "windows-py38-pytest54"
+ python: "3.8"
+ os: windows-latest
+ tox_env: "py38-pytest54"
- name: "ubuntu-py35"
python: "3.5"
@@ -64,6 +74,10 @@
python: "3.8"
os: ubuntu-latest
tox_env: "py38"
+ - name: "ubuntu-py39"
+ python: "3.9"
+ os: ubuntu-latest
+ tox_env: "py39"
- name: "ubuntu-py38-pytest53"
python: "3.8"
os: ubuntu-latest
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/pytest-subtests-0.3.2/CHANGELOG.rst
new/pytest-subtests-0.4.0/CHANGELOG.rst
--- old/pytest-subtests-0.3.2/CHANGELOG.rst 2020-08-01 17:00:34.000000000
+0200
+++ new/pytest-subtests-0.4.0/CHANGELOG.rst 2020-12-13 14:33:05.000000000
+0100
@@ -1,6 +1,13 @@
CHANGELOG
=========
+0.4.0 (2020-12-13)
+------------------
+
+* Add support for ``--pdb`` (`#22`_).
+
+.. _#22: https://github.com/pytest-dev/pytest-subtests/issues/22
+
0.3.2 (2020-08-01)
------------------
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/pytest-subtests-0.3.2/PKG-INFO
new/pytest-subtests-0.4.0/PKG-INFO
--- old/pytest-subtests-0.3.2/PKG-INFO 2020-08-01 17:00:45.000000000 +0200
+++ new/pytest-subtests-0.4.0/PKG-INFO 2020-12-13 14:33:19.000000000 +0100
@@ -1,6 +1,6 @@
Metadata-Version: 1.2
Name: pytest-subtests
-Version: 0.3.2
+Version: 0.4.0
Summary: unittest subTest() support and subtests fixture
Home-page: https://github.com/pytest-dev/pytest-subtests
Author: Bruno Oliveira
@@ -48,7 +48,22 @@
------------
* ``Python`` >= 3.5.
- * ``pytest`` >= 4.4.
+ * ``pytest`` >= 5.3.
+
+ pytest 6.2+
+ ^^^^^^^^^^^
+
+ ``pytest 6.2`` now issues a warning when internal classes are used by
third-party code,
+ which is the case for ``pytest-subtests`` which needs to use some
internal classes
+ to integrate with other pytest features (such as capturing and
debugging).
+
+ For now users can ignore those warnings by adding this to their
configuration file:
+
+ .. code-block:: ini
+
+ [pytest]
+ filterwarnings =
+ ignore:A private pytest class or function was
used.:PytestDeprecationWarning
Installation
------------
@@ -204,6 +219,7 @@
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
+Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Operating System :: OS Independent
Classifier: License :: OSI Approved :: MIT License
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/pytest-subtests-0.3.2/README.rst
new/pytest-subtests-0.4.0/README.rst
--- old/pytest-subtests-0.3.2/README.rst 2020-08-01 17:00:34.000000000
+0200
+++ new/pytest-subtests-0.4.0/README.rst 2020-12-13 14:33:05.000000000
+0100
@@ -38,7 +38,22 @@
------------
* ``Python`` >= 3.5.
-* ``pytest`` >= 4.4.
+* ``pytest`` >= 5.3.
+
+pytest 6.2+
+^^^^^^^^^^^
+
+``pytest 6.2`` now issues a warning when internal classes are used by
third-party code,
+which is the case for ``pytest-subtests`` which needs to use some internal
classes
+to integrate with other pytest features (such as capturing and debugging).
+
+For now users can ignore those warnings by adding this to their configuration
file:
+
+.. code-block:: ini
+
+ [pytest]
+ filterwarnings =
+ ignore:A private pytest class or function was
used.:PytestDeprecationWarning
Installation
------------
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/pytest-subtests-0.3.2/pytest_subtests.egg-info/PKG-INFO
new/pytest-subtests-0.4.0/pytest_subtests.egg-info/PKG-INFO
--- old/pytest-subtests-0.3.2/pytest_subtests.egg-info/PKG-INFO 2020-08-01
17:00:44.000000000 +0200
+++ new/pytest-subtests-0.4.0/pytest_subtests.egg-info/PKG-INFO 2020-12-13
14:33:18.000000000 +0100
@@ -1,6 +1,6 @@
Metadata-Version: 1.2
Name: pytest-subtests
-Version: 0.3.2
+Version: 0.4.0
Summary: unittest subTest() support and subtests fixture
Home-page: https://github.com/pytest-dev/pytest-subtests
Author: Bruno Oliveira
@@ -48,7 +48,22 @@
------------
* ``Python`` >= 3.5.
- * ``pytest`` >= 4.4.
+ * ``pytest`` >= 5.3.
+
+ pytest 6.2+
+ ^^^^^^^^^^^
+
+ ``pytest 6.2`` now issues a warning when internal classes are used by
third-party code,
+ which is the case for ``pytest-subtests`` which needs to use some
internal classes
+ to integrate with other pytest features (such as capturing and
debugging).
+
+ For now users can ignore those warnings by adding this to their
configuration file:
+
+ .. code-block:: ini
+
+ [pytest]
+ filterwarnings =
+ ignore:A private pytest class or function was
used.:PytestDeprecationWarning
Installation
------------
@@ -204,6 +219,7 @@
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
+Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Operating System :: OS Independent
Classifier: License :: OSI Approved :: MIT License
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/pytest-subtests-0.3.2/pytest_subtests.egg-info/requires.txt
new/pytest-subtests-0.4.0/pytest_subtests.egg-info/requires.txt
--- old/pytest-subtests-0.3.2/pytest_subtests.egg-info/requires.txt
2020-08-01 17:00:44.000000000 +0200
+++ new/pytest-subtests-0.4.0/pytest_subtests.egg-info/requires.txt
2020-12-13 14:33:18.000000000 +0100
@@ -1 +1 @@
-pytest>=4.4.0
+pytest>=5.3.0
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/pytest-subtests-0.3.2/pytest_subtests.py
new/pytest-subtests-0.4.0/pytest_subtests.py
--- old/pytest-subtests-0.3.2/pytest_subtests.py 2020-08-01
17:00:34.000000000 +0200
+++ new/pytest-subtests-0.4.0/pytest_subtests.py 2020-12-13
14:33:05.000000000 +0100
@@ -11,6 +11,7 @@
from _pytest.outcomes import OutcomeException
from _pytest.reports import TestReport
from _pytest.runner import CallInfo
+from _pytest.runner import check_interactive_exception
from _pytest.unittest import TestCaseFunction
if sys.version_info[:2] < (3, 7):
@@ -80,6 +81,10 @@
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)
+ if check_interactive_exception(call_info, sub_report):
+ self.ihook.pytest_exception_interact(
+ node=self, call=call_info, report=sub_report
+ )
def pytest_configure(config):
@@ -174,6 +179,11 @@
with self.suspend_capture_ctx():
self.ihook.pytest_runtest_logreport(report=sub_report)
+ if check_interactive_exception(call_info, sub_report):
+ self.ihook.pytest_exception_interact(
+ node=self.item, call=call_info, report=sub_report
+ )
+
def make_call_info(exc_info, *, start, stop, duration, when):
try:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/pytest-subtests-0.3.2/setup.py
new/pytest-subtests-0.4.0/setup.py
--- old/pytest-subtests-0.3.2/setup.py 2020-08-01 17:00:34.000000000 +0200
+++ new/pytest-subtests-0.4.0/setup.py 2020-12-13 14:33:05.000000000 +0100
@@ -23,7 +23,7 @@
use_scm_version=True,
setup_requires=["setuptools-scm", "setuptools>=40.0"],
python_requires=">=3.5",
- install_requires=["pytest>=4.4.0"],
+ install_requires=["pytest>=5.3.0"],
classifiers=[
"Development Status :: 4 - Beta",
"Framework :: Pytest",
@@ -35,6 +35,7 @@
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
+ "Programming Language :: Python :: 3.9",
"Programming Language :: Python :: Implementation :: CPython",
"Operating System :: OS Independent",
"License :: OSI Approved :: MIT License",
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/pytest-subtests-0.3.2/tests/test_subtests.py
new/pytest-subtests-0.4.0/tests/test_subtests.py
--- old/pytest-subtests-0.3.2/tests/test_subtests.py 2020-08-01
17:00:34.000000000 +0200
+++ new/pytest-subtests-0.4.0/tests/test_subtests.py 2020-12-13
14:33:05.000000000 +0100
@@ -3,6 +3,20 @@
import pytest
[email protected](autouse=True)
+def ignore_private_class_warning(testdir):
+ """
+ Make every test in this file ignore the warning about using private pytest
classes;
+ It is a risk we are willing to take in this plugin.
+ """
+ testdir.makeini(
+ """
+ [pytest]
+ filterwarnings = ignore:A private pytest class
+ """
+ )
+
+
@pytest.mark.parametrize("mode", ["normal", "xdist"])
class TestFixture:
"""
@@ -307,3 +321,63 @@
result.stdout.fnmatch_lines(
["*1 passed*",]
)
+
+
+class TestDebugging:
+ """Check --pdb support for subtests fixture and TestCase.subTest."""
+
+ class _FakePdb:
+ """
+ Fake debugger class implementation that tracks which methods were
called on it.
+ """
+
+ quitting = False
+ calls = []
+
+ def __init__(self, *args, **kwargs):
+ self.calls.append("init")
+
+ def reset(self):
+ self.calls.append("reset")
+
+ def interaction(self, *args):
+ self.calls.append("interaction")
+
+ @pytest.fixture(autouse=True)
+ def cleanup_calls(self):
+ self._FakePdb.calls.clear()
+
+ def test_pdb_fixture(self, testdir, monkeypatch):
+ testdir.makepyfile(
+ """
+ def test(subtests):
+ with subtests.test():
+ assert 0
+ """
+ )
+ self.runpytest_and_check_pdb(testdir, monkeypatch)
+
+ def test_pdb_unittest(self, testdir, monkeypatch):
+ testdir.makepyfile(
+ """
+ from unittest import TestCase
+ class Test(TestCase):
+ def test(self):
+ with self.subTest():
+ assert 0
+ """
+ )
+ self.runpytest_and_check_pdb(testdir, monkeypatch)
+
+ def runpytest_and_check_pdb(self, testdir, monkeypatch):
+ # Install the fake pdb implementation in pytest_subtests so we can
reference
+ # it in the command line (any module would do).
+ import pytest_subtests
+
+ monkeypatch.setattr(pytest_subtests, "_CustomPdb", self._FakePdb,
raising=False)
+ result = testdir.runpytest("--pdb",
"--pdbcls=pytest_subtests:_CustomPdb")
+
+ # Ensure pytest entered in debugging mode when encountering the failing
+ # assert.
+ result.stdout.fnmatch_lines("*entering PDB*")
+ assert self._FakePdb.calls == ["init", "reset", "interaction"]
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/pytest-subtests-0.3.2/tox.ini
new/pytest-subtests-0.4.0/tox.ini
--- old/pytest-subtests-0.3.2/tox.ini 2020-08-01 17:00:34.000000000 +0200
+++ new/pytest-subtests-0.4.0/tox.ini 2020-12-13 14:33:05.000000000 +0100
@@ -1,5 +1,5 @@
[tox]
-envlist = py35,py36,py37,py38,py38-pytest53,py38-pytest54,pypy3,linting
+envlist = py35,py36,py37,py38,py39,py38-pytest53,py38-pytest54,pypy3,linting
[testenv]
passenv = USER USERNAME TRAVIS PYTEST_ADDOPTS