forked from pool/python-betamax
Dirk Mueller
4a4a350451
- Add ``betamax_parametrized_recorder`` and ``betamax_parametrized_session`` to our list of pytest fixtures so that users will have parametrized cassette names when writing parametrized tests with our fixtures. (I wonder if I can mention parametrization a bunch more times so I can say parametrize a lot in this bullet note.) - Add ``ValidationError`` and a set of subclasses for each possible validation error. - Raise ``InvalidOption`` on unknown cassette options rather than silently ignoring extra options. - Raise a subclass of ``ValidationError`` when a particular cassette option is invalid, rather than silently ignoring the validation failure. - Fix bug with query string matcher where query-strings without values (e.g., ``?foo&bar`` as opposed to ``?foo=1&bar=2``) were treated as if there were no query string. - Fix issue #108 by effectively copying the items in the match_requests_on list into the match_options set on a Cassette instance OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-betamax?expand=0&rev=5
56 lines
1.7 KiB
RPMSpec
56 lines
1.7 KiB
RPMSpec
#
|
|
# spec file for package python-betamax
|
|
#
|
|
# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
|
|
#
|
|
# 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 http://bugs.opensuse.org/
|
|
#
|
|
|
|
|
|
Name: python-betamax
|
|
Version: 0.8.0
|
|
Release: 0
|
|
Summary: A VCR imitation for python-requests
|
|
License: Apache-2.0
|
|
Group: Development/Languages/Python
|
|
Url: https://github.com/sigmavirus24/betamax
|
|
Source: https://pypi.io/packages/source/b/betamax/betamax-%{version}.tar.gz
|
|
BuildRequires: python-devel
|
|
BuildRequires: python-setuptools
|
|
Requires: python-requests >= 2.0
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
%if 0%{?suse_version} && 0%{?suse_version} <= 1110
|
|
%{!?python_sitelib: %global python_sitelib %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
|
|
%else
|
|
BuildArch: noarch
|
|
%endif
|
|
|
|
%description
|
|
Betamax is a VCR_ imitation for requests. This will make mocking out requests
|
|
much easier.
|
|
|
|
%prep
|
|
%setup -q -n betamax-%{version}
|
|
|
|
%build
|
|
python setup.py build
|
|
|
|
%install
|
|
python setup.py install --prefix=%{_prefix} --root=%{buildroot}
|
|
|
|
%files
|
|
%defattr(-,root,root,-)
|
|
%doc AUTHORS.rst LICENSE README.rst
|
|
%{python_sitelib}/*
|
|
|
|
%changelog
|