Accepting request 708345 from home:mcalabkova:branches:devel:languages:python
- Update to version 2.12.0 * NOW support for Python 3.7 and Django 2.1 * various small bugfixes - Removed upstreamed patches: * python37.patch * django-2.2.patch OBS-URL: https://build.opensuse.org/request/show/708345 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-factory_boy?expand=0&rev=13
This commit is contained in:
parent
2332ad1c61
commit
68360073aa
@ -1,3 +0,0 @@
|
|||||||
version https://git-lfs.github.com/spec/v1
|
|
||||||
oid sha256:7d1038051d3bf468a4ec05a7e9e584985ad827e8af2badeefc93121f0e1a5633
|
|
||||||
size 137220
|
|
3
2.12.0.tar.gz
Normal file
3
2.12.0.tar.gz
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
version https://git-lfs.github.com/spec/v1
|
||||||
|
oid sha256:717c7f865f0228196f8170b09004c05e9576f78211986397abbabff565106c3f
|
||||||
|
size 142758
|
@ -1,22 +0,0 @@
|
|||||||
From a4c30d6529d3e613f5c2ac4cced7f985fda21041 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Federico Bond <federicobond@gmail.com>
|
|
||||||
Date: Tue, 2 Apr 2019 14:02:00 -0300
|
|
||||||
Subject: [PATCH] Fix test for Django 2.2
|
|
||||||
|
|
||||||
---
|
|
||||||
tests/test_django.py | 2 ++
|
|
||||||
1 file changed, 2 insertions(+)
|
|
||||||
|
|
||||||
diff --git a/tests/test_django.py b/tests/test_django.py
|
|
||||||
index 9a7827c..32b0539 100644
|
|
||||||
--- a/tests/test_django.py
|
|
||||||
+++ b/tests/test_django.py
|
|
||||||
@@ -137,6 +137,8 @@ class Meta:
|
|
||||||
|
|
||||||
|
|
||||||
class ModelTests(django_test.TestCase):
|
|
||||||
+ databases = {'default', 'replica'}
|
|
||||||
+
|
|
||||||
def test_unset_model(self):
|
|
||||||
class UnsetModelFactory(factory.django.DjangoModelFactory):
|
|
||||||
pass
|
|
@ -1,3 +1,13 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Jun 7 11:54:06 UTC 2019 - Marketa Calabkova <mcalabkova@suse.com>
|
||||||
|
|
||||||
|
- Update to version 2.12.0
|
||||||
|
* NOW support for Python 3.7 and Django 2.1
|
||||||
|
* various small bugfixes
|
||||||
|
- Removed upstreamed patches:
|
||||||
|
* python37.patch
|
||||||
|
* django-2.2.patch
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Wed Apr 17 10:14:58 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
|
Wed Apr 17 10:14:58 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
|
||||||
|
|
||||||
|
@ -18,21 +18,19 @@
|
|||||||
|
|
||||||
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
||||||
Name: python-factory_boy
|
Name: python-factory_boy
|
||||||
Version: 2.11.1
|
Version: 2.12.0
|
||||||
Release: 0
|
Release: 0
|
||||||
Summary: A test fixtures replacement
|
Summary: A test fixtures replacement
|
||||||
License: MIT
|
License: MIT
|
||||||
Group: Development/Languages/Python
|
Group: Development/Languages/Python
|
||||||
URL: http://github.com/rbarrois/factory_boy
|
URL: http://github.com/rbarrois/factory_boy
|
||||||
Source: https://github.com/FactoryBoy/factory_boy/archive/%{version}.tar.gz
|
Source: https://github.com/FactoryBoy/factory_boy/archive/%{version}.tar.gz
|
||||||
Patch0: python37.patch
|
|
||||||
Patch1: django-2.2.patch
|
|
||||||
BuildRequires: %{python_module Django}
|
BuildRequires: %{python_module Django}
|
||||||
BuildRequires: %{python_module Faker >= 0.7.0}
|
BuildRequires: %{python_module Faker >= 0.7.0}
|
||||||
BuildRequires: %{python_module Pillow}
|
BuildRequires: %{python_module Pillow}
|
||||||
BuildRequires: %{python_module flake8}
|
BuildRequires: %{python_module flake8}
|
||||||
BuildRequires: %{python_module mock}
|
BuildRequires: %{python_module mock}
|
||||||
BuildRequires: %{python_module setuptools}
|
BuildRequires: %{python_module setuptools >= 0.8}
|
||||||
BuildRequires: fdupes
|
BuildRequires: fdupes
|
||||||
BuildRequires: python-rpm-macros
|
BuildRequires: python-rpm-macros
|
||||||
BuildRequires: python2-ipaddress
|
BuildRequires: python2-ipaddress
|
||||||
@ -45,8 +43,6 @@ A test fixtures replacement based on thoughtbot's factory_girl for Ruby.
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n factory_boy-%{version}
|
%setup -q -n factory_boy-%{version}
|
||||||
%patch0 -p1
|
|
||||||
%patch1 -p1
|
|
||||||
# needs running mongo
|
# needs running mongo
|
||||||
rm tests/test_mongoengine.py
|
rm tests/test_mongoengine.py
|
||||||
sed -i -e '/test_mongoengine/d' tests/__init__.py
|
sed -i -e '/test_mongoengine/d' tests/__init__.py
|
||||||
|
@ -1,68 +0,0 @@
|
|||||||
From 97f48597d241aca598783f7bcaed34bf7b133343 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Jon Dufresne <jon.dufresne@gmail.com>
|
|
||||||
Date: Tue, 28 Aug 2018 04:40:26 -0700
|
|
||||||
Subject: [PATCH] Add testing and support for Python 3.7 and Django 2.1
|
|
||||||
|
|
||||||
Python 3.7 was released on June 27, 2018.
|
|
||||||
Django 2.1 was released on August 1, 2018.
|
|
||||||
|
|
||||||
https://docs.python.org/3/whatsnew/3.7.html
|
|
||||||
https://docs.djangoproject.com/en/2.1/releases/2.1/
|
|
||||||
|
|
||||||
Fixes #492
|
|
||||||
---
|
|
||||||
.travis.yml | 23 ++++++++++++++++++++---
|
|
||||||
README.rst | 2 +-
|
|
||||||
docs/changelog.rst | 3 ++-
|
|
||||||
factory/utils.py | 10 +++++++---
|
|
||||||
setup.py | 6 +++++-
|
|
||||||
tox.ini | 7 +++++--
|
|
||||||
6 files changed, 40 insertions(+), 11 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/factory/utils.py b/factory/utils.py
|
|
||||||
index 7bf38dd..15d87e4 100644
|
|
||||||
--- a/factory/utils.py
|
|
||||||
+++ b/factory/utils.py
|
|
||||||
@@ -73,9 +73,13 @@ def __iter__(self):
|
|
||||||
if self.next_elements:
|
|
||||||
yield self.next_elements.popleft()
|
|
||||||
else:
|
|
||||||
- value = next(self.iterator)
|
|
||||||
- self.past_elements.append(value)
|
|
||||||
- yield value
|
|
||||||
+ try:
|
|
||||||
+ value = next(self.iterator)
|
|
||||||
+ except StopIteration:
|
|
||||||
+ break
|
|
||||||
+ else:
|
|
||||||
+ self.past_elements.append(value)
|
|
||||||
+ yield value
|
|
||||||
|
|
||||||
def reset(self):
|
|
||||||
self.next_elements.clear()
|
|
||||||
diff --git a/setup.py b/setup.py
|
|
||||||
index 4291c80..07fb60a 100755
|
|
||||||
--- a/setup.py
|
|
||||||
+++ b/setup.py
|
|
||||||
@@ -51,8 +51,11 @@ def get_version(package_name):
|
|
||||||
],
|
|
||||||
classifiers=[
|
|
||||||
"Development Status :: 5 - Production/Stable",
|
|
||||||
- "Intended Audience :: Developers",
|
|
||||||
"Framework :: Django",
|
|
||||||
+ "Framework :: Django :: 1.11",
|
|
||||||
+ "Framework :: Django :: 2.0",
|
|
||||||
+ "Framework :: Django :: 2.1",
|
|
||||||
+ "Intended Audience :: Developers",
|
|
||||||
"License :: OSI Approved :: MIT License",
|
|
||||||
"Operating System :: OS Independent",
|
|
||||||
"Programming Language :: Python",
|
|
||||||
@@ -62,6 +65,7 @@ def get_version(package_name):
|
|
||||||
"Programming Language :: Python :: 3.4",
|
|
||||||
"Programming Language :: Python :: 3.5",
|
|
||||||
"Programming Language :: Python :: 3.6",
|
|
||||||
+ "Programming Language :: Python :: 3.7",
|
|
||||||
"Programming Language :: Python :: Implementation :: PyPy",
|
|
||||||
"Topic :: Software Development :: Testing",
|
|
||||||
"Topic :: Software Development :: Libraries :: Python Modules",
|
|
||||||
|
|
Loading…
x
Reference in New Issue
Block a user