From 022aa81efddfdc80b02d34b3578a141ef6f152b0 Mon Sep 17 00:00:00 2001 From: Python Maint Date: Fri, 7 Jun 2024 08:58:32 +0200 Subject: [PATCH 01/14] Rebuilt for Python 3.13 --- python-pycotap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/python-pycotap.spec b/python-pycotap.spec index cae6cb6..1f99894 100644 --- a/python-pycotap.spec +++ b/python-pycotap.spec @@ -3,7 +3,7 @@ Name: python-%{pypi_name} Version: 1.1.0 -Release: 20%{?dist} +Release: 21%{?dist} Summary: A tiny test runner that outputs TAP results to standard output License: MIT @@ -49,6 +49,9 @@ find %{buildroot}/%{python3_sitelib} -name '*.py' | xargs sed -i '/^#!/d' %{python3_sitelib}/%{pypi_name}-%{version}-py%{python3_version}.egg-info %changelog +* Fri Jun 07 2024 Python Maint - 1.1.0-21 +- Rebuilt for Python 3.13 + * Fri Jan 26 2024 Fedora Release Engineering - 1.1.0-20 - Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild From 778897daf8d54ca4b1bc34406fc9e240badd4b48 Mon Sep 17 00:00:00 2001 From: Shlomi Fish Date: Fri, 12 Jul 2024 13:31:24 +0300 Subject: [PATCH 02/14] New upstream release ( RHBZ#2297455 ) New upstream release ( https://bugzilla.redhat.com/show_bug.cgi?id=2297455 ) --- .gitignore | 1 + python-pycotap.spec | 8 ++++++-- sources | 2 +- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index b7e1a35..0a2089f 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ /pycotap-1.1.0.tar.gz +/pycotap-1.3.1.tar.gz diff --git a/python-pycotap.spec b/python-pycotap.spec index 1f99894..21a2e87 100644 --- a/python-pycotap.spec +++ b/python-pycotap.spec @@ -2,8 +2,8 @@ %global pypi_name pycotap Name: python-%{pypi_name} -Version: 1.1.0 -Release: 21%{?dist} +Version: 1.3.1 +Release: 1%{?dist} Summary: A tiny test runner that outputs TAP results to standard output License: MIT @@ -43,12 +43,16 @@ rm -rf %{pypi_name}.egg-info %install %py3_install find %{buildroot}/%{python3_sitelib} -name '*.py' | xargs sed -i '/^#!/d' +%__rm -f %{buildroot}/usr/COPYING %files -n python3-%{pypi_name} %{python3_sitelib}/%{pypi_name} %{python3_sitelib}/%{pypi_name}-%{version}-py%{python3_version}.egg-info %changelog +* Fri Jul 12 2024 Shlomi Fish 1.3.1-1 +- New upstream release ( https://bugzilla.redhat.com/show_bug.cgi?id=2297455 ) + * Fri Jun 07 2024 Python Maint - 1.1.0-21 - Rebuilt for Python 3.13 diff --git a/sources b/sources index dccda8e..8f8a5f4 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (pycotap-1.1.0.tar.gz) = dbe8d76c3e4b934dd4ff9ec0d48caafef3ae5583046a7316607b3c8cebf8cb920c68dc46487243aac81823994805c76f2be8ff0cbda593c70b70f268661fa289 +SHA512 (pycotap-1.3.1.tar.gz) = e7d50340fb4e3f55037a96aaaba419e6753d4499564339b6562317455ed223c3fd93bf41d0bd9654c03a4bea09377daa192ca985bafc96983e4a2261dde348b8 From 9a8a210796bff0330fba21eb65fa5af4569a416b Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Fri, 19 Jul 2024 14:23:16 +0000 Subject: [PATCH 03/14] Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild --- python-pycotap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/python-pycotap.spec b/python-pycotap.spec index 21a2e87..d1b493a 100644 --- a/python-pycotap.spec +++ b/python-pycotap.spec @@ -3,7 +3,7 @@ Name: python-%{pypi_name} Version: 1.3.1 -Release: 1%{?dist} +Release: 2%{?dist} Summary: A tiny test runner that outputs TAP results to standard output License: MIT @@ -50,6 +50,9 @@ find %{buildroot}/%{python3_sitelib} -name '*.py' | xargs sed -i '/^#!/d' %{python3_sitelib}/%{pypi_name}-%{version}-py%{python3_version}.egg-info %changelog +* Fri Jul 19 2024 Fedora Release Engineering - 1.3.1-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild + * Fri Jul 12 2024 Shlomi Fish 1.3.1-1 - New upstream release ( https://bugzilla.redhat.com/show_bug.cgi?id=2297455 ) From 18333d7f240f50536b5aaf5872d84a31c84e7d1d Mon Sep 17 00:00:00 2001 From: Takao Fujiwara Date: Sat, 12 Oct 2024 01:22:26 +0900 Subject: [PATCH 04/14] Delete CI STI --- tests/tests.py | 53 ------------------------------------------------- tests/tests.yml | 13 ------------ 2 files changed, 66 deletions(-) delete mode 100755 tests/tests.py delete mode 100644 tests/tests.yml diff --git a/tests/tests.py b/tests/tests.py deleted file mode 100755 index 8c08d32..0000000 --- a/tests/tests.py +++ /dev/null @@ -1,53 +0,0 @@ -#!/usr/bin/python3 -# -*- coding: utf-8 -*- - -from __future__ import print_function - -import sys -import unittest - -# Need to flush the output against Gtk.main() -def printflush(sentence): - try: - print(sentence, flush=True) - except IOError: - pass - -def printerr(sentence): - try: - print(sentence, flush=True, file=sys.stderr) - except IOError: - pass - -from pycotap import TAPTestRunner -from pycotap import LogMode -printflush('## Load pycotap') - - -class AnthyTest(unittest.TestCase): - __test_index = 0 - - @classmethod - def setUpClass(cls): - printflush('## setUpclass done') - cls.__test_index += 1 - - def setUp(self): - self.__test_index += 1 - printflush('## setUp done') - - def test_case1(self): - if self.__test_index != 2: - with self.subTest(i = self.__test_index): - self.fail('setUp does not run: ' + error.message) - printflush('## Test done %d' % self.__test_index) - - -def main(): - loader = unittest.TestLoader() - # Log should be in stderr instead of StringIO - runner = TAPTestRunner(test_output_log=LogMode.LogToError) - unittest.main(testRunner=runner, testLoader=loader) - -if __name__ == '__main__': - main() diff --git a/tests/tests.yml b/tests/tests.yml deleted file mode 100644 index 22f5154..0000000 --- a/tests/tests.yml +++ /dev/null @@ -1,13 +0,0 @@ -- hosts: localhost - tags: - - classic - roles: - - role: standard-test-basic - #- role: standard-test-beakerlib - required_packages: - - python3-pycotap - tests: - - smoke1: - dir: . - run: ./tests.py - From 7f31276577006d994290e5838033eaf082180c63 Mon Sep 17 00:00:00 2001 From: Takao Fujiwara Date: Sat, 12 Oct 2024 01:23:34 +0900 Subject: [PATCH 05/14] Add CI TMT --- .fmf/version | 1 + plans/test.fmf | 5 +++++ tests/base/main.fmf | 5 +++++ tests/base/test.py | 37 +++++++++++++++++++++++++++++++++++++ tests/base/test.sh | 9 +++++++++ 5 files changed, 57 insertions(+) create mode 100644 .fmf/version create mode 100644 plans/test.fmf create mode 100644 tests/base/main.fmf create mode 100755 tests/base/test.py create mode 100755 tests/base/test.sh diff --git a/.fmf/version b/.fmf/version new file mode 100644 index 0000000..d00491f --- /dev/null +++ b/.fmf/version @@ -0,0 +1 @@ +1 diff --git a/plans/test.fmf b/plans/test.fmf new file mode 100644 index 0000000..c1627f9 --- /dev/null +++ b/plans/test.fmf @@ -0,0 +1,5 @@ +summary: Basic smoke test +discover: + how: fmf +execute: + how: tmt diff --git a/tests/base/main.fmf b/tests/base/main.fmf new file mode 100644 index 0000000..d657f11 --- /dev/null +++ b/tests/base/main.fmf @@ -0,0 +1,5 @@ +summary: Simple test of python-pycotap +test: ./test.sh +framework: beakerlib +require: + - python3-pycotap diff --git a/tests/base/test.py b/tests/base/test.py new file mode 100755 index 0000000..4f6f6e2 --- /dev/null +++ b/tests/base/test.py @@ -0,0 +1,37 @@ +#!/usr/bin/python3 +# -*- coding: utf-8 -*- + +import unittest +import sys + +from pycotap import TAPTestRunner +from pycotap import LogMode + + +class SimpleTest(unittest.TestCase): + @classmethod + def function_name(cls): + sys.stdout = sys.__stdout__ + return sys._getframe().f_back.f_code.co_name + + @classmethod + def setUpClass(cls): + print(cls.function_name()) + + def setUp(self): + print(SimpleTest.function_name()) + + def main(self): + print(SimpleTest.function_name()) + + def test_foo(self): + print(SimpleTest.function_name()) + + +def main(): + loader = unittest.TestLoader() + runner = TAPTestRunner(test_output_log=LogMode.LogToError) + unittest.main(testRunner=runner, testLoader=loader) + +if __name__ == '__main__': + main() diff --git a/tests/base/test.sh b/tests/base/test.sh new file mode 100755 index 0000000..b61d891 --- /dev/null +++ b/tests/base/test.sh @@ -0,0 +1,9 @@ +#!/bin/bash +# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +rlJournalStart + rlPhaseStartTest + rlRun -t "./test.py" + rlPhaseEnd +rlJournalEnd From 488eb5dbbddb2416279fe7ba725ab00d881c6871 Mon Sep 17 00:00:00 2001 From: Takao Fujiwara Date: Sat, 12 Oct 2024 01:26:41 +0900 Subject: [PATCH 06/14] Rebuilt for CI --- python-pycotap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/python-pycotap.spec b/python-pycotap.spec index d1b493a..5a23611 100644 --- a/python-pycotap.spec +++ b/python-pycotap.spec @@ -3,7 +3,7 @@ Name: python-%{pypi_name} Version: 1.3.1 -Release: 2%{?dist} +Release: 3%{?dist} Summary: A tiny test runner that outputs TAP results to standard output License: MIT @@ -50,6 +50,9 @@ find %{buildroot}/%{python3_sitelib} -name '*.py' | xargs sed -i '/^#!/d' %{python3_sitelib}/%{pypi_name}-%{version}-py%{python3_version}.egg-info %changelog +* Fri Oct 11 2024 Takao Fujiwara 1.3.1-3 +- Rebuilt for CI + * Fri Jul 19 2024 Fedora Release Engineering - 1.3.1-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild From cdc6c05e876eac47ac043abf908637ce1ba18f43 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Sat, 18 Jan 2025 17:37:55 +0000 Subject: [PATCH 07/14] Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild --- python-pycotap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/python-pycotap.spec b/python-pycotap.spec index 5a23611..7077753 100644 --- a/python-pycotap.spec +++ b/python-pycotap.spec @@ -3,7 +3,7 @@ Name: python-%{pypi_name} Version: 1.3.1 -Release: 3%{?dist} +Release: 4%{?dist} Summary: A tiny test runner that outputs TAP results to standard output License: MIT @@ -50,6 +50,9 @@ find %{buildroot}/%{python3_sitelib} -name '*.py' | xargs sed -i '/^#!/d' %{python3_sitelib}/%{pypi_name}-%{version}-py%{python3_version}.egg-info %changelog +* Sat Jan 18 2025 Fedora Release Engineering - 1.3.1-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild + * Fri Oct 11 2024 Takao Fujiwara 1.3.1-3 - Rebuilt for CI From 91ceded8a2600ec07b75e8ba1bf0d08241ea0ba3 Mon Sep 17 00:00:00 2001 From: Shlomi Fish Date: Thu, 13 Feb 2025 19:53:34 +0200 Subject: [PATCH 08/14] update stale URL --- python-pycotap.spec | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/python-pycotap.spec b/python-pycotap.spec index 7077753..09518a1 100644 --- a/python-pycotap.spec +++ b/python-pycotap.spec @@ -3,11 +3,11 @@ Name: python-%{pypi_name} Version: 1.3.1 -Release: 4%{?dist} +Release: 5%{?dist} Summary: A tiny test runner that outputs TAP results to standard output License: MIT -URL: https://el-tramo.be/pycotap +URL: https://github.com/remko/pycotap Source0: %{pypi_source} BuildArch: noarch @@ -16,7 +16,7 @@ BuildRequires: python3dist(setuptools) %description pycotap is a simple Python test runner for unit tests that outputs Test Anything -Protocol results directly to standard output.Contrary to other TAP runners +Protocol results directly to standard output. Contrary to other TAP runners for Python, pycotap prints TAP (and *only* TAP) to standard output instead of to a separate file, allowing you to pipe it directly to TAP pretty printers and processors. @@ -27,7 +27,7 @@ Summary: %{summary} %description -n python3-%{pypi_name} pycotap is a simple Python test runner for unit tests that outputs Test Anything -Protocol results directly to standard output.Contrary to other TAP runners +Protocol results directly to standard output. Contrary to other TAP runners for Python, pycotap prints TAP (and *only* TAP) to standard output instead of to a separate file, allowing you to pipe it directly to TAP pretty printers and processors. @@ -50,6 +50,9 @@ find %{buildroot}/%{python3_sitelib} -name '*.py' | xargs sed -i '/^#!/d' %{python3_sitelib}/%{pypi_name}-%{version}-py%{python3_version}.egg-info %changelog +* Thu Feb 13 2025 Shlomi Fish 1.3.1-5 +- Update URL. + * Sat Jan 18 2025 Fedora Release Engineering - 1.3.1-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild From 8fd88ca7a2c4438702e9d18afaf13b81245a0037 Mon Sep 17 00:00:00 2001 From: Python Maint Date: Mon, 2 Jun 2025 20:35:25 +0200 Subject: [PATCH 09/14] Rebuilt for Python 3.14 --- python-pycotap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/python-pycotap.spec b/python-pycotap.spec index 09518a1..7f0fe53 100644 --- a/python-pycotap.spec +++ b/python-pycotap.spec @@ -3,7 +3,7 @@ Name: python-%{pypi_name} Version: 1.3.1 -Release: 5%{?dist} +Release: 6%{?dist} Summary: A tiny test runner that outputs TAP results to standard output License: MIT @@ -50,6 +50,9 @@ find %{buildroot}/%{python3_sitelib} -name '*.py' | xargs sed -i '/^#!/d' %{python3_sitelib}/%{pypi_name}-%{version}-py%{python3_version}.egg-info %changelog +* Mon Jun 02 2025 Python Maint - 1.3.1-6 +- Rebuilt for Python 3.14 + * Thu Feb 13 2025 Shlomi Fish 1.3.1-5 - Update URL. From e5fa98bc82814bbcd74e6324f83106f4b9af8af0 Mon Sep 17 00:00:00 2001 From: Shlomi Fish Date: Wed, 9 Jul 2025 05:44:07 +0300 Subject: [PATCH 10/14] deprecated macros [ RHBZ#2378026 ] --- python-pycotap.spec | 26 +++++++++++++++----------- 1 file changed, 15 insertions(+), 11 deletions(-) diff --git a/python-pycotap.spec b/python-pycotap.spec index 7f0fe53..86e055f 100644 --- a/python-pycotap.spec +++ b/python-pycotap.spec @@ -1,9 +1,8 @@ -# Created by pyp2rpm-3.3.2 %global pypi_name pycotap Name: python-%{pypi_name} Version: 1.3.1 -Release: 6%{?dist} +Release: 7%{?dist} Summary: A tiny test runner that outputs TAP results to standard output License: MIT @@ -12,7 +11,6 @@ Source0: %{pypi_source} BuildArch: noarch BuildRequires: python3-devel -BuildRequires: python3dist(setuptools) %description pycotap is a simple Python test runner for unit tests that outputs Test Anything @@ -23,7 +21,6 @@ printers and processors. %package -n python3-%{pypi_name} Summary: %{summary} -%{?python_provide:%python_provide python3-%{pypi_name}} %description -n python3-%{pypi_name} pycotap is a simple Python test runner for unit tests that outputs Test Anything @@ -34,22 +31,29 @@ printers and processors. %prep %autosetup -n %{pypi_name}-%{version} -# Remove bundled egg-info -rm -rf %{pypi_name}.egg-info + +%generate_buildrequires +%pyproject_buildrequires %build -%py3_build +%pyproject_wheel %install -%py3_install +%pyproject_install +%pyproject_save_files %{pypi_name} find %{buildroot}/%{python3_sitelib} -name '*.py' | xargs sed -i '/^#!/d' %__rm -f %{buildroot}/usr/COPYING -%files -n python3-%{pypi_name} -%{python3_sitelib}/%{pypi_name} -%{python3_sitelib}/%{pypi_name}-%{version}-py%{python3_version}.egg-info +%check +%pyproject_check_import + +%files -n python3-%{pypi_name} -f %{pyproject_files} %changelog +======= +* Wed Jul 09 2025 Shlomi Fish 1.3.1-7 +- Stop using deprecated RPM macros ( https://bugzilla.redhat.com/show_bug.cgi?id=2378026 ) + * Mon Jun 02 2025 Python Maint - 1.3.1-6 - Rebuilt for Python 3.14 From 1afe2ec237ae6cba2728a365a044e6ac0d4046a0 Mon Sep 17 00:00:00 2001 From: Shlomi Fish Date: Wed, 9 Jul 2025 05:52:26 +0300 Subject: [PATCH 11/14] deprecated macros [ RHBZ#2378026 ] --- python-pycotap.spec | 1 - 1 file changed, 1 deletion(-) diff --git a/python-pycotap.spec b/python-pycotap.spec index 86e055f..42f0ca1 100644 --- a/python-pycotap.spec +++ b/python-pycotap.spec @@ -50,7 +50,6 @@ find %{buildroot}/%{python3_sitelib} -name '*.py' | xargs sed -i '/^#!/d' %files -n python3-%{pypi_name} -f %{pyproject_files} %changelog -======= * Wed Jul 09 2025 Shlomi Fish 1.3.1-7 - Stop using deprecated RPM macros ( https://bugzilla.redhat.com/show_bug.cgi?id=2378026 ) From ec3fad94bf9265a9921a22df7165dc5efce4d684 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Fri, 25 Jul 2025 09:33:21 +0000 Subject: [PATCH 12/14] Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild --- python-pycotap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/python-pycotap.spec b/python-pycotap.spec index 42f0ca1..d3182a9 100644 --- a/python-pycotap.spec +++ b/python-pycotap.spec @@ -2,7 +2,7 @@ Name: python-%{pypi_name} Version: 1.3.1 -Release: 7%{?dist} +Release: 8%{?dist} Summary: A tiny test runner that outputs TAP results to standard output License: MIT @@ -50,6 +50,9 @@ find %{buildroot}/%{python3_sitelib} -name '*.py' | xargs sed -i '/^#!/d' %files -n python3-%{pypi_name} -f %{pyproject_files} %changelog +* Fri Jul 25 2025 Fedora Release Engineering - 1.3.1-8 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild + * Wed Jul 09 2025 Shlomi Fish 1.3.1-7 - Stop using deprecated RPM macros ( https://bugzilla.redhat.com/show_bug.cgi?id=2378026 ) From 2e0144badd269b070d2f8e2c23a767db50102c85 Mon Sep 17 00:00:00 2001 From: Python Maint Date: Fri, 15 Aug 2025 14:28:17 +0200 Subject: [PATCH 13/14] Rebuilt for Python 3.14.0rc2 bytecode --- python-pycotap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/python-pycotap.spec b/python-pycotap.spec index d3182a9..b0d4050 100644 --- a/python-pycotap.spec +++ b/python-pycotap.spec @@ -2,7 +2,7 @@ Name: python-%{pypi_name} Version: 1.3.1 -Release: 8%{?dist} +Release: 9%{?dist} Summary: A tiny test runner that outputs TAP results to standard output License: MIT @@ -50,6 +50,9 @@ find %{buildroot}/%{python3_sitelib} -name '*.py' | xargs sed -i '/^#!/d' %files -n python3-%{pypi_name} -f %{pyproject_files} %changelog +* Fri Aug 15 2025 Python Maint - 1.3.1-9 +- Rebuilt for Python 3.14.0rc2 bytecode + * Fri Jul 25 2025 Fedora Release Engineering - 1.3.1-8 - Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild From 6be50fb74dc293b1421f411294a38c13c44edacc Mon Sep 17 00:00:00 2001 From: Python Maint Date: Fri, 19 Sep 2025 14:03:58 +0200 Subject: [PATCH 14/14] Rebuilt for Python 3.14.0rc3 bytecode --- python-pycotap.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/python-pycotap.spec b/python-pycotap.spec index b0d4050..aea5e80 100644 --- a/python-pycotap.spec +++ b/python-pycotap.spec @@ -2,7 +2,7 @@ Name: python-%{pypi_name} Version: 1.3.1 -Release: 9%{?dist} +Release: 10%{?dist} Summary: A tiny test runner that outputs TAP results to standard output License: MIT @@ -50,6 +50,9 @@ find %{buildroot}/%{python3_sitelib} -name '*.py' | xargs sed -i '/^#!/d' %files -n python3-%{pypi_name} -f %{pyproject_files} %changelog +* Fri Sep 19 2025 Python Maint - 1.3.1-10 +- Rebuilt for Python 3.14.0rc3 bytecode + * Fri Aug 15 2025 Python Maint - 1.3.1-9 - Rebuilt for Python 3.14.0rc2 bytecode