Compare commits

1 Commits
main ... 1.1

7 changed files with 27 additions and 116 deletions

View File

@@ -1,3 +0,0 @@
<multibuild>
<package>test</package>
</multibuild>

View File

@@ -1,41 +1,3 @@
-------------------------------------------------------------------
Mon Sep 23 14:06:48 UTC 2024 - Markéta Machová <mmachova@suse.com>
- Update to 2.7.2
* Treat methodName="runTest" similar to unittest.TestCase,
fixes compatibility with pytest 8.3. (Natanael Copa, #372)
* Use ruff for linting. (Jelmer Vernooij)
* Fix compatibility with Python 3.12.1. (Matthew Treinish)
* Deprecate SkippedTest exception. (Stephen Finucane)
* Drop support for Python 3.7. (Jelmer Vernooij)
- Drop merged pytest82.patch
- Add upstream twisted.patch to fix tests with new Twisted
-------------------------------------------------------------------
Fri May 17 14:07:33 UTC 2024 - Markéta Machová <mmachova@suse.com>
- Add pytest82.patch to fix functionality with the new pytest.
-------------------------------------------------------------------
Wed May 8 06:42:24 UTC 2024 - Steve Kowalik <steven.kowalik@suse.com>
- Drop the now unneeded rpmlintrc.
- Clean up BuildRequires and Requires to match reality.
- Add missing _multibuild file.
-------------------------------------------------------------------
Sat Dec 30 20:31:27 UTC 2023 - Dirk Müller <dmueller@suse.com>
- update to 2.7.1:
* Remove various unused imports.
* Fix build backend. This should prevent version from being set
when building wheels.
* Fix compatibility with Python 3.12.
* Add typing in various modules (still lacking full coverage).
* Drop the 'test' command for distutils. This has been
deprecated since 2.6.0. (Jelmer Vernooij)
* Drop support for Python 3.6.
------------------------------------------------------------------- -------------------------------------------------------------------
Thu May 4 21:18:15 UTC 2023 - Dirk Müller <dmueller@suse.com> Thu May 4 21:18:15 UTC 2023 - Dirk Müller <dmueller@suse.com>
@@ -120,7 +82,7 @@ Sat Oct 16 19:29:27 UTC 2021 - Dirk Müller <dmueller@suse.com>
* Test on GitHub Actions * Test on GitHub Actions
* Remove stray six import * Remove stray six import
* Testtools 2.4.0 is the last to support Python 2.7 * Testtools 2.4.0 is the last to support Python 2.7
- remove python-testtools-no-unittest2.patch (upstream) - remove python-testtools-no-unittest2.patch (upstream)
------------------------------------------------------------------- -------------------------------------------------------------------
Thu Jun 11 08:21:52 UTC 2020 - pgajdos@suse.com Thu Jun 11 08:21:52 UTC 2020 - pgajdos@suse.com
@@ -224,7 +186,7 @@ Sun Apr 2 09:48:51 UTC 2017 - aloisio@gmx.com
------------------------------------------------------------------- -------------------------------------------------------------------
Mon Feb 27 07:31:26 UTC 2017 - shshyukriev@suse.com Mon Feb 27 07:31:26 UTC 2017 - shshyukriev@suse.com
- BuildRequires also using extras>=1.0.0 - BuildRequires also using extras>=1.0.0
------------------------------------------------------------------- -------------------------------------------------------------------
Thu Sep 1 12:43:29 UTC 2016 - tbechtold@suse.com Thu Sep 1 12:43:29 UTC 2016 - tbechtold@suse.com
@@ -445,7 +407,7 @@ Tue Aug 30 11:41:55 UTC 2016 - tbechtold@suse.com
------------------------------------------------------------------- -------------------------------------------------------------------
Mon Dec 1 22:48:47 UTC 2014 - dmueller@suse.com Mon Dec 1 22:48:47 UTC 2014 - dmueller@suse.com
- fix typo in last change - fix typo in last change
------------------------------------------------------------------- -------------------------------------------------------------------
Mon Dec 1 17:04:18 UTC 2014 - rhafer@suse.com Mon Dec 1 17:04:18 UTC 2014 - rhafer@suse.com
@@ -570,7 +532,7 @@ Thu Aug 8 13:47:56 UTC 2013 - speilicke@suse.com
Thu Aug 8 13:22:20 UTC 2013 - speilicke@suse.com Thu Aug 8 13:22:20 UTC 2013 - speilicke@suse.com
- Totally disable testing to bootstrap ppc64. Actually the build conditional is - Totally disable testing to bootstrap ppc64. Actually the build conditional is
supposed to do just that. supposed to do just that.
------------------------------------------------------------------- -------------------------------------------------------------------
Tue Jun 25 11:35:04 UTC 2013 - speilicke@suse.com Tue Jun 25 11:35:04 UTC 2013 - speilicke@suse.com
@@ -597,7 +559,7 @@ Fri Jun 21 08:21:16 UTC 2013 - speilicke@suse.com
------------------------------------------------------------------- -------------------------------------------------------------------
Mon May 6 11:25:43 UTC 2013 - dmueller@suse.com Mon May 6 11:25:43 UTC 2013 - dmueller@suse.com
- add python-mmimeparse dependency - add python-mmimeparse dependency
------------------------------------------------------------------- -------------------------------------------------------------------
Tue Apr 23 09:33:35 UTC 2013 - p.drouand@gmail.com Tue Apr 23 09:33:35 UTC 2013 - p.drouand@gmail.com
@@ -633,13 +595,13 @@ Tue Jan 15 16:43:28 UTC 2013 - p.drouand@gmail.com
Mon Jan 14 12:38:00 UTC 2013 - saschpe@suse.de Mon Jan 14 12:38:00 UTC 2013 - saschpe@suse.de
- Update to version 0.9.24: - Update to version 0.9.24:
* testtools.run discover will now sort the tests it discovered. This is a * testtools.run discover will now sort the tests it discovered. This is a
workaround for http://bugs.python.org/issue16709. Non-standard test suites workaround for http://bugs.python.org/issue16709. Non-standard test suites
are preserved, and their sort_tests() method called (if they have such an are preserved, and their sort_tests() method called (if they have such an
attribute). testtools.testsuite.sorted_tests(suite, True) can be used by attribute). testtools.testsuite.sorted_tests(suite, True) can be used by
such suites to do a local sort. such suites to do a local sort.
* ThreadsafeForwardingResult now defines a stub progress method, which * ThreadsafeForwardingResult now defines a stub progress method, which
fixes testr run of streams containing progress markers (by discarding the fixes testr run of streams containing progress markers (by discarding the
progress data). progress data).
- Changes from version 0.9.23: - Changes from version 0.9.23:
* run.TestToolsTestRunner now accepts the verbosity, buffer and failfast * run.TestToolsTestRunner now accepts the verbosity, buffer and failfast

View File

@@ -0,0 +1 @@
addFilter("E: python-tests-in-package.*/usr/lib/.*/site-packages/testtools/tests")

View File

@@ -1,7 +1,7 @@
# #
# spec file for package python-testtools # spec file
# #
# Copyright (c) 2024 SUSE LLC # Copyright (c) 2023 SUSE LLC
# #
# All modifications and additions to the file contributed by third parties # All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed # remain the property of their copyright owners, unless otherwise agreed
@@ -26,29 +26,26 @@
%endif %endif
%{?sle15_python_module_pythons} %{?sle15_python_module_pythons}
Name: python-testtools%{psuffix} Name: python-testtools%{psuffix}
Version: 2.7.2 Version: 2.6.0
Release: 0 Release: 0
Summary: Extensions to the Python Standard Library Unit Testing Framework Summary: Extensions to the Python Standard Library Unit Testing Framework
License: MIT License: MIT
Group: Development/Languages/Python
URL: https://github.com/testing-cabal/testtools URL: https://github.com/testing-cabal/testtools
Source0: https://files.pythonhosted.org/packages/source/t/testtools/testtools-%{version}.tar.gz Source0: https://files.pythonhosted.org/packages/source/t/testtools/testtools-%{version}.tar.gz
# PATCH-FIX-UPSTREAM https://github.com/testing-cabal/testtools/commit/5b8cb6497c7159f593e68de6a13e15f7e78e56e3 Prepare tests for upcoming twisted version Source99: python-testtools.rpmlintrc
Patch0: twisted.patch BuildRequires: %{python_module pbr}
BuildRequires: %{python_module hatch_vcs} BuildRequires: %{python_module setuptools}
BuildRequires: %{python_module pip}
BuildRequires: %{python_module wheel}
BuildRequires: fdupes BuildRequires: fdupes
BuildRequires: python-rpm-macros BuildRequires: python-rpm-macros
Requires: python-Twisted Requires: python-pbr >= 0.11
%if %python_version_nodots > 311 Requires: python-python-mimeparse
Requires: python-setuptools Requires: python-traceback2
%endif
BuildArch: noarch BuildArch: noarch
%if %{with test} %if %{with test}
BuildRequires: %{python_module fixtures} BuildRequires: %{python_module python-mimeparse}
BuildRequires: %{python_module testresources}
BuildRequires: %{python_module testscenarios} BuildRequires: %{python_module testscenarios}
BuildRequires: %{python_module testtools = %{version}} BuildRequires: %{python_module traceback2}
%endif %endif
Recommends: python-fixtures >= 2.0 Recommends: python-fixtures >= 2.0
%python_subpackages %python_subpackages
@@ -60,16 +57,16 @@ with unit tests in Python and come from many different sources. testtools
also ports recent unittest changes all the way back to Python 2.4. also ports recent unittest changes all the way back to Python 2.4.
%prep %prep
%autosetup -p1 -n testtools-%{version} %setup -q -n testtools-%{version}
%if !%{with test} %if !%{with test}
%build %build
%pyproject_wheel %python_build
%endif %endif
%if !%{with test} %if !%{with test}
%install %install
%pyproject_install %python_install
%python_expand %fdupes %{buildroot}%{$python_sitelib} %python_expand %fdupes %{buildroot}%{$python_sitelib}
%endif %endif
@@ -83,7 +80,7 @@ also ports recent unittest changes all the way back to Python 2.4.
%license LICENSE %license LICENSE
%doc NEWS README.rst %doc NEWS README.rst
%{python_sitelib}/testtools %{python_sitelib}/testtools
%{python_sitelib}/testtools-%{version}.dist-info %{python_sitelib}/testtools-%{version}-py*.egg-info
%endif %endif
%changelog %changelog

BIN
testtools-2.6.0.tar.gz (Stored with Git LFS) Normal file

Binary file not shown.

BIN
testtools-2.7.2.tar.gz (Stored with Git LFS)

Binary file not shown.

View File

@@ -1,46 +0,0 @@
From 5b8cb6497c7159f593e68de6a13e15f7e78e56e3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Petr=20Van=C4=9Bk?= <arkamar@atlas.cz>
Date: Mon, 1 Jul 2024 10:00:05 +0200
Subject: [PATCH] Prepare tests for upcoming twisted version
Twisted recently changed behavior of logger on failures [1]. It newly
logs the `Main loop terminated.` even on exceptions, which breaks two
test in twistedsupport test suite. This hack attempts to address the
upcoming issue.
[1] https://github.com/twisted/twisted/pull/12207
---
testtools/tests/twistedsupport/test_runtest.py | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/testtools/tests/twistedsupport/test_runtest.py b/testtools/tests/twistedsupport/test_runtest.py
index 4b46cc64..f8faf7c6 100644
--- a/testtools/tests/twistedsupport/test_runtest.py
+++ b/testtools/tests/twistedsupport/test_runtest.py
@@ -16,7 +16,6 @@
Contains,
ContainsAll,
ContainsDict,
- EndsWith,
Equals,
Is,
KeysEqual,
@@ -749,7 +748,7 @@ def test_something(self):
test,
{
"traceback": Not(Is(None)),
- "twisted-log": AsText(EndsWith(" foo\n")),
+ "twisted-log": AsText(Contains(" foo\n")),
},
),
("stopTest", test),
@@ -790,7 +789,8 @@ def test_something(self):
result = self.make_result()
runner.run(result)
self.assertThat(
- messages, MatchesListwise([ContainsDict({"message": Equals(("foo",))})])
+ messages[0:1],
+ MatchesListwise([ContainsDict({"message": Equals(("foo",))})]),
)
def test_restore_observers(self):