- Update to 1.3.0:

* add tests for ufuncs without docstrings, wrapped or not by @lpsinger in #248
  * Update skips for broken test by @lpsinger in #249
  * Fix multiline code in generate/update diff by @seberg in #253
  * Remove accidental debug print from new tests by @seberg in #254
  * refactored out runtime dependency on setuptools by @neutrinoceros in #258
  * adding python3.13 to CI and fix any incompatibilities by @bsipocz in #260
  * add one more python release to xfail list by @bsipocz in #266
  * Use hash for Action workflow versions and update if needed by @pllim in #267
  * Don't assume config exists. by @Carreau in #271
- Add add-missing-xfail-version.patch to fix broken test

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:pytest/python-pytest-doctestplus?expand=0&rev=39
This commit is contained in:
2024-12-20 05:50:21 +00:00
committed by Git OBS Bridge
commit 42dea7e2e9
8 changed files with 325 additions and 0 deletions

23
.gitattributes vendored Normal file
View File

@@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

1
.gitignore vendored Normal file
View File

@@ -0,0 +1 @@
.osc

3
_multibuild Normal file
View File

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

View File

@@ -0,0 +1,22 @@
From 23eb3de76bc4581dfc8261b07a8a55cc03fea45b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Brigitta=20Sip=C5=91cz?= <bsipocz@gmail.com>
Date: Mon, 16 Dec 2024 19:05:07 -0800
Subject: [PATCH] TST: one more version to xfail
---
tests/test_doctestplus.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tests/test_doctestplus.py b/tests/test_doctestplus.py
index a88ca7b..fb0ac37 100644
--- a/tests/test_doctestplus.py
+++ b/tests/test_doctestplus.py
@@ -1142,7 +1142,7 @@ def f():
@pytest.mark.xfail(
- python_version() in ('3.11.9', '3.11.10', '3.12.3'),
+ python_version() in ('3.11.9', '3.11.10', '3.11.11', '3.12.3'),
reason='broken by https://github.com/python/cpython/pull/115440')
def test_ufunc(testdir):
pytest.importorskip('numpy')

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:2472a8a2c8cea34d2f65f6499543faeb748eecb59c597852fd98839b47307679
size 45896

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:709ad23ea98da9a835ace0a4365c85371c376e000f2860f30de6df3a6f00728a
size 46843

View File

@@ -0,0 +1,179 @@
-------------------------------------------------------------------
Thu Dec 19 10:11:47 UTC 2024 - Nico Krapp <nico.krapp@suse.com>
- Update to 1.3.0:
* add tests for ufuncs without docstrings, wrapped or not by @lpsinger in #248
* Update skips for broken test by @lpsinger in #249
* Fix multiline code in generate/update diff by @seberg in #253
* Remove accidental debug print from new tests by @seberg in #254
* refactored out runtime dependency on setuptools by @neutrinoceros in #258
* adding python3.13 to CI and fix any incompatibilities by @bsipocz in #260
* add one more python release to xfail list by @bsipocz in #266
* Use hash for Action workflow versions and update if needed by @pllim in #267
* Don't assume config exists. by @Carreau in #271
- Add add-missing-xfail-version.patch to fix broken test
-------------------------------------------------------------------
Sat Mar 16 12:59:47 UTC 2024 - Dirk Müller <dmueller@suse.com>
- update to 1.2.1:
* Compatibility with pytest 8.1.1
* Compatibility with pytest 8.1.
-------------------------------------------------------------------
Sun Dec 31 13:32:06 UTC 2023 - Dirk Müller <dmueller@suse.com>
- update to 1.1.0:
* Added --doctest-plus-generate-diff to update documentation
based on actual output.
* Fix module level __doctest_requires__.
* Versions of Python <3.8 are no longer supported.
* Fix erroneous attempt to import __main__.py by skipping it.
* Respect pytest --import-mode.
-------------------------------------------------------------------
Wed Oct 4 12:48:36 UTC 2023 - Ben Greiner <code@bnavigator.de>
- Update to 1.0.0
* Changing GitHub organization.
-------------------------------------------------------------------
Mon Jul 24 18:57:08 UTC 2023 - Dirk Müller <dmueller@suse.com>
- update to 0.13.0:
* Compatibility with pytest 7.4 with respect to
``norecursedirs`` handling. [#201]
* Respect ``--doctest-continue-on-failure`` flag. [#197]
* Report doctests raising skip exceptions as skipped. [#196]
-------------------------------------------------------------------
Thu May 4 22:39:44 UTC 2023 - Dirk Müller <dmueller@suse.com>
- update to 0.12.1:
* Allow floating point comparison in Python dictionary. [#186]
-------------------------------------------------------------------
Tue Aug 16 16:18:41 UTC 2022 - Ben Greiner <code@bnavigator.de>
- Fix test requirement of pytest-remotedata
-------------------------------------------------------------------
Sun Mar 13 08:57:08 UTC 2022 - Ben Greiner <code@bnavigator.de>
- Update to 0.12.0
* MNT: Stop using distutils by @pllim in #172
* Add --doctest-ufunc option to doctest Numpy ufuncs by @lpsinger
in #174
* Fix typos by @kianmeng in #176
* Doctests in ufuncs should respect doctest_skip by @lpsinger in
#175
* Use windows-2019 for GitHub Actions jobs by @lpsinger in #178
-------------------------------------------------------------------
Sun Oct 17 13:49:48 UTC 2021 - Ben Greiner <code@bnavigator.de>
- Update to 0.11.0
* Added support for testcleanup and documented existing support
for testsetup. [#165]
- Release 0.10.1
* Fix the doctestplus sphinx extension to recognize the
doctest-remote-data directive. [#162]
- Release 0.10.0
* Added ..doctest-remote-data:: directive to control remote data
access for a chunk of code. [#137]
* Drop support for python 3.6. [#159]
* Fixed a bug where the command-line option --remote-data=any
(associated with the pytest-remotedata plugin) would cause
IGNORE_WARNINGS and SHOW_WARNINGS options to be ignored in
module docstrings. [#152]
* Fix wrong behavior with IGNORE_WARNINGS and SHOW_WARNINGS that
could make a block to pass instead of being skipped. [#148]
-------------------------------------------------------------------
Sun May 2 08:42:25 UTC 2021 - Ben Greiner <code@bnavigator.de>
- Update to 0.9.0
* Declare setuptools runtime dependency. [#93]
* Add SHOW_WARNINGS flag to show warnings. [#136]
* Add the doctestplus sphinx extension. [#113]
* Compatibility with pytest>=6.3 [#140, #141]
-------------------------------------------------------------------
Tue Aug 25 13:53:35 UTC 2020 - Marketa Calabkova <mcalabkova@suse.com>
- Update to 0.8.0
* Compatibility with ``pytest`` 6.0.0. [#120]
-------------------------------------------------------------------
Tue Jun 9 08:05:00 UTC 2020 - Tomáš Chvátal <tchvatal@suse.com>
- Update to 0.7.0:
* Added a new ini option, doctest_subpackage_requires, that can
be used to skip specific subpackages based on required packages. [#112]
-------------------------------------------------------------------
Mon May 18 09:18:14 UTC 2020 - Tomáš Chvátal <tchvatal@suse.com>
- Update to 0.6.1:
* Disabling the usage of the doctest_ignore_import_errors option
* Drop support for python versions earlier than 3.6. [#103]
* Drop support for pytest versions earlier than 4.0. [#103]
* Fix compatibility with pytest 5.4. [#103]
-------------------------------------------------------------------
Mon Nov 18 08:01:54 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
- Update to 0.5.0:
* No longer require Numpy. [#69]
* Fixed a bug that caused __doctest_requires__ to not work correctly with submodules. [#73]
* Fixed a limitation that meant that ELLIPSIS and FLOAT_CMP could not be used at the same time. [#75]
* Fixed a bug that caused .. doctest-requires:: to not work correctly. [#78]
* Fixed a FutureWarning related to split() with regular expressions. [#78]
* Make it possible to specify versions in .. doctest-requires::. [#78]
* Allow to use doctest-glob option instead of doctest-rst and text-file-format [#80]
* Make comment character configurable via ini variable text_file_comment_chars [#80]
* Respect ignore and ignore-glob options from pytest. [#82]
* Add --doctest-only option. [#83]
* Added an IGNORE_WARNINGS option for # doctest: [#84]
- Remove merged patch pr_37.patch
-------------------------------------------------------------------
Fri Sep 20 09:47:57 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
- Update to 0.4.0:
* Avoid SyntaxWarning regarding invalid escape sequence in Python 3.9. [#62]
* Compatibility with pytest 5.1 to avoid AttributeError caused by FixtureRequest. [#63]
- Drop merged patch:
* merged_pr_63.patch
- Rebase patch:
* pr_37.patch
-------------------------------------------------------------------
Fri Sep 6 16:53:49 UTC 2019 - John Vandenberg <jayvdb@gmail.com>
- Add merged_pr_63.patch to fix incompatibility with pytest 5.1
- Add pr_37.patch to remove numpy dependency
-------------------------------------------------------------------
Fri Mar 8 11:10:23 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
- Update to 0.3.0:
* Honor the collect_ignore option used in conftest.py. [#36]
* Make use of doctest_optionflags settings. [#39]
* Make it possible to set FLOAT_CMP globally in setup.cfg. [#40]
* Drop support for pytest versions earlier than 3.0. [#46]
* Extend doctest-skip, doctest-skip-all, and doctest-requires directives to work in TeX files. [#43]
-------------------------------------------------------------------
Thu Feb 14 12:22:53 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
- Update to 0.2.0:
* Add doctest-plus-atol and doctest-plus-rtol options for setting the numerical tolerance. [#21]
* Update behavior of --doctest-modules option when plugin is installed. [#26]
- Switch to github tarball to obtain tests
- Enable tests using _multibuild
-------------------------------------------------------------------
Tue Aug 14 20:03:23 UTC 2018 - toddrme2178@gmail.com
- Initial version

View File

@@ -0,0 +1,91 @@
#
# spec file for package python-pytest-doctestplus
#
# Copyright (c) 2024 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%global flavor @BUILD_FLAVOR@%{nil}
%if "%{flavor}" == "test"
%define psuffix -test
%bcond_without test
%else
%define psuffix %{nil}
%bcond_with test
%endif
%{?sle15_python_module_pythons}
Name: python-pytest-doctestplus%{psuffix}
Version: 1.3.0
Release: 0
Summary: Pytest plugin with advanced doctest features
License: BSD-3-Clause
URL: https://github.com/scientific-python/pytest-doctestplus
Source: https://files.pythonhosted.org/packages/source/p/pytest-doctestplus/pytest_doctestplus-%{version}.tar.gz
# PATCH-FIX-UPSTREAM add-missing-xfail-version.patch (gh#23eb3de)
Patch0: add-missing-xfail-version.patch
BuildRequires: %{python_module base >= 3.8}
BuildRequires: %{python_module pip}
BuildRequires: %{python_module setuptools_scm}
BuildRequires: %{python_module wheel}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
Requires: python-packaging >= 17.0
Requires: python-pytest >= 4.6
%if %{with test}
BuildRequires: %{python_module Sphinx}
BuildRequires: %{python_module numpy-devel}
BuildRequires: %{python_module numpy}
BuildRequires: %{python_module pip >= 19.3.1}
BuildRequires: %{python_module pytest-doctestplus = %{version}}
BuildRequires: %{python_module pytest-remotedata >= 0.3.2}
BuildRequires: git-core
%else
BuildArch: noarch
%endif
%python_subpackages
%description
This package contains a plugin for the pytest framework that provides
advanced doctest support and enables the testing of various text files, such
as reStructuredText (".rst"), markdown (".md"), and TeX (".tex").
%prep
%autosetup -p1 -n pytest_doctestplus-%{version}
%build
%pyproject_wheel
%install
%if !%{with test}
%pyproject_install
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%endif
%if %{with test}
%check
export LANG=en_US.UTF8
export PY_IGNORE_IMPORTMISMATCH=1
%pytest tests/ --doctest-plus --doctest-rst -k "not test_remote_data_url and not test_import_mode"
%endif
%if !%{with test}
%files %{python_files}
%doc CHANGES.rst README.rst
%license LICENSE.rst
%{python_sitelib}/pytest_doctestplus
%{python_sitelib}/pytest_doctestplus-%{version}.dist-info
%endif
%changelog