From 6f29e6da9a4baec7e3db61c0a6a08f0c7bfd9cb7ba155c717c6ec966d4b8510b Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Tue, 12 Nov 2024 21:12:40 +0000 Subject: [PATCH] ok OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:pytest/python-pytest-recording?expand=0&rev=1 --- .gitattributes | 23 ++++++++++ .gitignore | 1 + pytest-recording-0.13.2.tar.gz | 3 ++ python-pytest-recording.changes | 4 ++ python-pytest-recording.spec | 74 +++++++++++++++++++++++++++++++++ 5 files changed, 105 insertions(+) create mode 100644 .gitattributes create mode 100644 .gitignore create mode 100644 pytest-recording-0.13.2.tar.gz create mode 100644 python-pytest-recording.changes create mode 100644 python-pytest-recording.spec diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -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 diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..57affb6 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.osc diff --git a/pytest-recording-0.13.2.tar.gz b/pytest-recording-0.13.2.tar.gz new file mode 100644 index 0000000..7e9e9d9 --- /dev/null +++ b/pytest-recording-0.13.2.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:979a7849e758ed1d6ba17056533c75ac901f30a420d8229342bf4c5043cb86fb +size 24993 diff --git a/python-pytest-recording.changes b/python-pytest-recording.changes new file mode 100644 index 0000000..2bed6a3 --- /dev/null +++ b/python-pytest-recording.changes @@ -0,0 +1,4 @@ +------------------------------------------------------------------- +Tue Nov 12 13:20:45 UTC 2024 - Martin Hauke + +- Initial package, version 0.13.2 diff --git a/python-pytest-recording.spec b/python-pytest-recording.spec new file mode 100644 index 0000000..7a45af5 --- /dev/null +++ b/python-pytest-recording.spec @@ -0,0 +1,74 @@ +# +# spec file for package python-pytest-recording +# +# Copyright (c) 2024, Martin Hauke +# +# 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/ +# + + +Name: python-pytest-recording +Version: 0.13.2 +Release: 0 +Summary: A pytest plugin that allows you recording of network interactions via VCRpy +License: MIT +URL: https://github.com/kiwicom/pytest-recording +Source: https://github.com/kiwicom/pytest-recording/archive/refs/tags/v%{version}.tar.gz#/pytest-recording-%{version}.tar.gz +BuildRequires: python-rpm-macros +BuildRequires: %{python_module hatchling} +BuildRequires: %{python_module pip} +# SECTION test requirements +BuildRequires: %{python_module pytest >= 3.5.0} +BuildRequires: %{python_module vcrpy >= 2.0.1} +BuildRequires: %{python_module requests} +BuildRequires: %{python_module pytest-httpbin} +BuildRequires: %{python_module pytest-mock} +# /SECTION +BuildRequires: fdupes +Requires: python-pytest >= 3.5.0 +Requires: python-vcrpy >= 2.0.1 +BuildArch: noarch +%python_subpackages + +%description +A pytest plugin that records network interactions in your tests +via VCR.py. + +Features + * Straightforward `pytest.mark.vcr`, that reflects + `VCR.use_cassettes` API; + * Combining multiple VCR cassettes + * Network access blocking; + * The `rewrite` recording mode that rewrites cassettes + from scratch. + +%prep +%autosetup -p1 -n pytest-recording-%{version} + +%build +%pyproject_wheel + +%install +%pyproject_install +%python_expand %fdupes %{buildroot}%{$python_sitelib} + +%check +# skip tests that require a network connection +%pytest -k "not (test_block_network_with_allowed_hosts or test_block_network_with_allowed_hosts or test_block_network_with_allowed_hosts or test_blocked)" + +%files %{python_files} +%license LICENSE +%doc README.rst +%{python_sitelib}/pytest_recording +%{python_sitelib}/pytest_recording-%{version}.dist-info + +%changelog