1
0
python-factory_boy/python-factory_boy.spec
Dirk Mueller 9815bc2571 Accepting request 893466 from home:bnavigator:branches:devel:languages:python
- Update to v3.2.0
  * Add support for Django 3.1
  * Add support for Python 3.9
  * Drop support for Django 1.11. This version is not maintained
    anymore.
  * Drop support for Python 3.5. This version is not maintained
    anymore.
  Deprecated:
  * factory.use_strategy(). Use factory.FactoryOptions.strategy
    instead. The purpose of use_strategy() duplicates the factory
    option. Follow PEP 20: There should be one– and preferably only
    one –obvious way to do it.
  * use_strategy() will be removed in the next major version.
  Bug fix:
  * Calls to factory.Faker and factory.django.FileField within a
    Trait or Maybe no longer lead to a KeyError crash.
- Remove python2 build conditional: Not supported upstream

OBS-URL: https://build.opensuse.org/request/show/893466
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-factory_boy?expand=0&rev=21
2021-05-16 14:09:32 +00:00

68 lines
2.0 KiB
RPMSpec

#
# spec file for package python-factory_boy
#
# Copyright (c) 2021 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/
#
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%define skip_python2 1
Name: python-factory_boy
Version: 3.2.0
Release: 0
Summary: Python test fixtures
License: MIT
URL: https://github.com/rbarrois/factory_boy
Source: https://files.pythonhosted.org/packages/source/f/factory_boy/factory_boy-%{version}.tar.gz
BuildRequires: %{python_module Django}
BuildRequires: %{python_module Faker >= 0.7.0}
BuildRequires: %{python_module Pillow}
BuildRequires: %{python_module setuptools >= 0.8}
BuildRequires: %{pythons}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
Requires: python-Faker >= 0.7.0
BuildArch: noarch
%python_subpackages
%description
A test fixtures replacement based on thoughtbot's factory_girl for Ruby.
%prep
%setup -q -n factory_boy-%{version}
# needs running mongo
rm tests/test_mongoengine.py
sed -i -e '/test_mongoengine/d' tests/__init__.py
# sqlalchemy hickups a lot
rm tests/test_alchemy.py
sed -i -e '/test_alchemy/d' tests/__init__.py
%build
%python_build
%install
%python_install
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%check
%pyunittest -v
%files %{python_files}
%license LICENSE
%doc README.rst
%{python_sitelib}/factory
%{python_sitelib}/factory_boy-%{version}*-info
%changelog