Accepting request 944519 from devel:languages:python:pytest
OBS-URL: https://build.opensuse.org/request/show/944519 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-pytest-twisted?expand=0&rev=4
This commit is contained in:
3
pytest-twisted-1.13.4-gh.tar.gz
Normal file
3
pytest-twisted-1.13.4-gh.tar.gz
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:e767e9a648b8068524de02d79bbcb9c5dcc6f4ede046b88ca6aeba723af5ab81
|
||||
size 15687
|
39
pytest-twisted-ignorepy310DeprecationWarnings.patch
Normal file
39
pytest-twisted-ignorepy310DeprecationWarnings.patch
Normal file
@@ -0,0 +1,39 @@
|
||||
Index: pytest-twisted-1.13.4/pytest.ini
|
||||
===================================================================
|
||||
--- pytest-twisted-1.13.4.orig/pytest.ini
|
||||
+++ pytest-twisted-1.13.4/pytest.ini
|
||||
@@ -1,3 +1,5 @@
|
||||
[pytest]
|
||||
addopts = --verbose
|
||||
-filterwarnings = error
|
||||
+filterwarnings =
|
||||
+ error
|
||||
+ ignore:currentThread:DeprecationWarning
|
||||
Index: pytest-twisted-1.13.4/testing/test_basic.py
|
||||
===================================================================
|
||||
--- pytest-twisted-1.13.4.orig/testing/test_basic.py
|
||||
+++ pytest-twisted-1.13.4/testing/test_basic.py
|
||||
@@ -94,8 +94,13 @@ def skip_if_no_async_generators():
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
-def cmd_opts(request):
|
||||
+def cmd_opts(request, testdir):
|
||||
reactor = request.config.getoption("reactor", "default")
|
||||
+ pytest_ini_file = """
|
||||
+ [pytest]
|
||||
+ filterwarnings = ignore:currentThread:DeprecationWarning
|
||||
+ """
|
||||
+ testdir.makefile(".ini", pytest=pytest_ini_file)
|
||||
return (
|
||||
sys.executable,
|
||||
"-m",
|
||||
@@ -370,6 +375,8 @@ def test_async_fixture(testdir, cmd_opts
|
||||
[pytest]
|
||||
markers =
|
||||
redgreenblue
|
||||
+ filterwarnings =
|
||||
+ ignore:currentThread:DeprecationWarning
|
||||
"""
|
||||
testdir.makefile('.ini', pytest=pytest_ini_file)
|
||||
test_file = """
|
@@ -1,3 +1,11 @@
|
||||
-------------------------------------------------------------------
|
||||
Thu Jan 6 17:21:12 UTC 2022 - Ben Greiner <code@bnavigator.de>
|
||||
|
||||
- Update to 1.13.4
|
||||
* no release notes
|
||||
- Add pytest-twisted-ignorepy310DeprecationWarnings.patch
|
||||
gh#pytest-dev/pytest-twisted/146
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Nov 5 13:51:00 UTC 2020 - Marketa Machova <mmachova@suse.com>
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package python-pytest-twisted
|
||||
#
|
||||
# Copyright (c) 2020 SUSE LLC
|
||||
# Copyright (c) 2022 SUSE LLC
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
@@ -18,13 +18,15 @@
|
||||
|
||||
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
||||
Name: python-pytest-twisted
|
||||
Version: 1.13.2
|
||||
Version: 1.13.4
|
||||
Release: 0
|
||||
Summary: Pytest Plugin for Twisted
|
||||
License: BSD-2-Clause
|
||||
Group: Development/Languages/Python
|
||||
URL: https://github.com/pytest-dev/pytest-twisted
|
||||
Source: https://github.com/pytest-dev/pytest-twisted/archive/v%{version}.tar.gz
|
||||
Source: https://github.com/pytest-dev/pytest-twisted/archive/v%{version}.tar.gz#/pytest-twisted-%{version}-gh.tar.gz
|
||||
# PATCH-FIX-OPENSUSE pytest-twisted-ignorepy310DeprecationWarnings.patch -- upstream wants this fixed in twisted itself -- gh#pytest-dev/pytest-twisted/146
|
||||
Patch0: pytest-twisted-ignorepy310DeprecationWarnings.patch
|
||||
BuildRequires: %{python_module Twisted}
|
||||
BuildRequires: %{python_module decorator}
|
||||
BuildRequires: %{python_module greenlet}
|
||||
@@ -46,7 +48,7 @@ which uses the twisted framework. test functions can return Deferred
|
||||
objects and pytest will wait for their completion with this plugin.
|
||||
|
||||
%prep
|
||||
%setup -q -n pytest-twisted-%{version}
|
||||
%autosetup -p1 -n pytest-twisted-%{version}
|
||||
|
||||
%build
|
||||
%python_build
|
||||
@@ -56,14 +58,13 @@ objects and pytest will wait for their completion with this plugin.
|
||||
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
||||
|
||||
%check
|
||||
export PYTHONDONTWRITEBYTECODE=1
|
||||
# test_inline_callbacks_in_pytest_deprecation - breaks with the new pytest 5.x series
|
||||
# test_blockon_in_pytest_deprecation - breaks with the new pytest 5.x series
|
||||
%pytest -k 'not test_blockon_in_pytest_deprecation and not test_inline_callbacks_in_pytest_deprecation'
|
||||
%pytest
|
||||
|
||||
%files %{python_files}
|
||||
%license LICENSE
|
||||
%doc README.rst
|
||||
%{python_sitelib}/*
|
||||
%{python_sitelib}/pytest_twisted.py*
|
||||
%pycache_only %{python_sitelib}/__pycache__/pytest_twisted.*
|
||||
%{python_sitelib}/pytest_twisted-%{version}*-info
|
||||
|
||||
%changelog
|
||||
|
@@ -1,3 +0,0 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:64a75354cf81d00f1642169b786fcde3130b98ae886f6380978d18e975660102
|
||||
size 15076
|
Reference in New Issue
Block a user