Commit Graph

35 Commits

Author SHA256 Message Date
Ana Guerrero
9efcbee070 Accepting request 1125175 from devel:languages:python
- Update to 3.3.0
  * New:
    - :issue:`366`: Add :class:`factory.django.Password` to generate Django 
      :class:`~django.contrib.auth.models.User` passwords.
    - :issue:`304`: Add :attr:`~factory.alchemy.SQLAlchemyOptions.sqlalchemy_session_factory`
      to dynamically create sessions for use by the :class:`~factory.alchemy.SQLAlchemyModelFactory`.
    - Add support for Django 4.0
    - Add support for Django 4.1
    - Add support for Python 3.10
    - Add support for Python 3.11
  * Bugfix:
    - Make :meth:`~factory.django.mute_signals` mute signals during post-generation.
    - :issue:`775`: Change the signature for :meth:`~factory.alchemy.SQLAlchemyModelFactory._save`
      and :meth:`~factory.alchemy.SQLAlchemyModelFactory._get_or_create` to avoid argument names
      clashes with a field named session.
  * Deprecated:
    - :class:`~factory.django.DjangoModelFactory` will stop issuing
      a second call to :meth:`~django.db.models.Model.save` on the
      created instance when :ref:`post-generation-hooks` return a value.
    - To help with the transition, :class:`factory.django.DjangoModelFactory._after_postgeneration`
      raises a :class:`DeprecationWarning` when calling :meth:`~django.db.models.Model.save`.
      Inspect your :class:`~factory.django.DjangoModelFactory` subclasses:
      + If the :meth:`~django.db.models.Model.save` call is not needed after :class:`~factory.PostGeneration`, set   
        :attr:`factory.django.DjangoOptions.skip_postgeneration_save` to True in the factory meta.
      + Otherwise, the instance has been modified by :class:`~factory.PostGeneration`
        hooks and needs to be :meth:`~django.db.models.Model.save`d. Either:
        - call :meth:`django.db.models.Model.save` in the :class:`~factory.PostGeneration`
          hook that modifies the instance, or
        - override :class:`~factory.django.DjangoModelFactory._after_postgeneration`
          to :meth:`~django.db.models.Model.save` the instance.

OBS-URL: https://build.opensuse.org/request/show/1125175
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-factory_boy?expand=0&rev=20
2023-11-13 21:15:47 +00:00
4dde887c74 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-factory_boy?expand=0&rev=32 2023-11-11 16:09:00 +00:00
805f1b42f3 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-factory_boy?expand=0&rev=31 2023-11-11 16:08:41 +00:00
ef56998143 Accepting request 1124433 from home:ecsos:python
- Update to 3.3.0
  * New:
    - :issue:`366`: Add :class:`factory.django.Password` to generate Django 
      :class:`~django.contrib.auth.models.User` passwords.
    - :issue:`304`: Add :attr:`~factory.alchemy.SQLAlchemyOptions.sqlalchemy_session_factory`
      to dynamically create sessions for use by the :class:`~factory.alchemy.SQLAlchemyModelFactory`.
    - Add support for Django 4.0
    - Add support for Django 4.1
    - Add support for Python 3.10
    - Add support for Python 3.11
  * Bugfix:
    - Make :meth:`~factory.django.mute_signals` mute signals during post-generation.
    - :issue:`775`: Change the signature for :meth:`~factory.alchemy.SQLAlchemyModelFactory._save`
      and :meth:`~factory.alchemy.SQLAlchemyModelFactory._get_or_create` to avoid argument names
      clashes with a field named session.
  * Deprecated:
    - :class:`~factory.django.DjangoModelFactory` will stop issuing
      a second call to :meth:`~django.db.models.Model.save` on the
      created instance when :ref:`post-generation-hooks` return a value.
    - To help with the transition, :class:`factory.django.DjangoModelFactory._after_postgeneration`
      raises a :class:`DeprecationWarning` when calling :meth:`~django.db.models.Model.save`.
      Inspect your :class:`~factory.django.DjangoModelFactory` subclasses:
      + If the :meth:`~django.db.models.Model.save` call is not needed after :class:`~factory.PostGeneration`, set   
        :attr:`factory.django.DjangoOptions.skip_postgeneration_save` to True in the factory meta.
      + Otherwise, the instance has been modified by :class:`~factory.PostGeneration`
        hooks and needs to be :meth:`~django.db.models.Model.save`d. Either:
        - call :meth:`django.db.models.Model.save` in the :class:`~factory.PostGeneration`
          hook that modifies the instance, or
        - override :class:`~factory.django.DjangoModelFactory._after_postgeneration`
          to :meth:`~django.db.models.Model.save` the instance.
  * Removed:
    - Drop support for Django 2.2
    - Drop support for Django 3.0
    - Drop support for Django 3.1
    - Drop support for Python 3.6
    - Drop support for Python 3.7
- Drop tests-skip-django-py36.patch because new version need 
  python >= 3.7.

OBS-URL: https://build.opensuse.org/request/show/1124433
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-factory_boy?expand=0&rev=30
2023-11-11 16:08:21 +00:00
Dominique Leuenberger
c49ce5b3c4 Accepting request 1083112 from devel:languages:python
- add sle15_python_module_pythons (jsc#PED-68)

OBS-URL: https://build.opensuse.org/request/show/1083112
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-factory_boy?expand=0&rev=19
2023-04-28 14:22:14 +00:00
991fa1fbaf - add sle15_python_module_pythons (jsc#PED-68)
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-factory_boy?expand=0&rev=28
2023-04-26 20:38:48 +00:00
Dominique Leuenberger
41dc48d421 Accepting request 1062545 from devel:languages:python
- skip testing with Django on SLE15

OBS-URL: https://build.opensuse.org/request/show/1062545
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-factory_boy?expand=0&rev=18
2023-02-03 21:04:34 +00:00
98b8193440 - skip testing with Django on SLE15
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-factory_boy?expand=0&rev=26
2023-02-01 20:48:41 +00:00
Dominique Leuenberger
bd92c501fd Accepting request 946656 from devel:languages:python
- update to 3.2.1:
  - Add support for Django 3.2
  - Do not override signals receivers registered in a :meth:`~factory.django.mute_signals` context.

OBS-URL: https://build.opensuse.org/request/show/946656
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-factory_boy?expand=0&rev=17
2022-01-17 21:33:50 +00:00
9b41eec4fb - update to 3.2.1:
- Add support for Django 3.2
  - Do not override signals receivers registered in a :meth:`~factory.django.mute_signals` context.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-factory_boy?expand=0&rev=25
2022-01-15 16:04:48 +00:00
Dominique Leuenberger
d21f515826 Accepting request 942993 from devel:languages:python
- Add missing BR typing_extensions
- Add tests-skip-django-py36.patch -- no Django 4 for python36

OBS-URL: https://build.opensuse.org/request/show/942993
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-factory_boy?expand=0&rev=16
2021-12-30 14:55:20 +00:00
c0bdb65fd1 - Add missing BR typing_extensions
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-factory_boy?expand=0&rev=24
2021-12-28 22:54:49 +00:00
8588f7e5bc Accepting request 942834 from home:bnavigator:branches:devel:languages:python
OBS-URL: https://build.opensuse.org/request/show/942834
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-factory_boy?expand=0&rev=23
2021-12-28 11:53:24 +00:00
Dominique Leuenberger
d06dadfed5 Accepting request 893472 from devel:languages:python
OBS-URL: https://build.opensuse.org/request/show/893472
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-factory_boy?expand=0&rev=15
2021-05-16 21:42:03 +00:00
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
Dominique Leuenberger
06e3e96e22 Accepting request 839487 from devel:languages:python
OBS-URL: https://build.opensuse.org/request/show/839487
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-factory_boy?expand=0&rev=14
2020-10-23 10:18:30 +00:00
Tomáš Chvátal
0823e31173 Accepting request 839483 from home:jayvdb:branches:devel:languages:python
- Use PyPI tarball and revise test runner to python -m unittest
- Update to v3.1.0
  * Allow all types of declarations in :class:`factory.Faker` calls
    enables references to other faker-defined attributes.
- from v3.0.1
  * Fix `import factory; factory.django.DjangoModelFactory` and
    similar calls.
- from v3.0.0
  * Removed alias
    + `from factory import DjangoModelFactory` to
      `from factory.django import DjangoModelFactory`
    + `from factory import MogoFactory` to
      `from factory.mogo import MogoFactory`
    + `from factory.fuzzy import get_random_state` to
      `from factory.random import get_random_state`
    + `from factory.fuzzy import set_random_state` to
      `from factory.random import set_random_state`
    + `from factory.fuzzy import reseed_random` to
      `from factory.random import reseed_random`
  * Drop support for Python 2 and 3.4
  * Drop support for Django 2.0 and 2.1
  * Remove deprecated `force_flush` from `SQLAlchemyModelFactory`
    Use `sqlalchemy_session_persistence = "flush"` instead
  * Drop deprecated `attributes()` from `factory.Factory`; use
    `make_factory(dict, FactoryClass._meta.pre_declarations)`
  * Drop deprecated `declarations()` from `factory.Factory`; use
    `FactoryClass._meta.pre_declarations` instead
  * Drop `factory.compat` module
  * Add support for Python 3.8
  * Add support for Django 2.2 and 3.0
  * Report misconfiguration when `Factory` is used
    as the `Factory.model` for another `Factory`
  * Allow configuring the color palette of `factory.django.ImageField`
  * `get_random_state()` now represents the state of Faker and
    `factory_boy` fuzzy attributes
  * Add SQLAlchemy ``get_or_create`` support
  * Display a developer-friendly error message when providing a model
    instead of a factory in a `factory.declarations.SubFactory` class
  * Fix issue with SubFactory not preserving signal muting behaviour
    of the used factory
  * Fix issue with overriding params in a Trait
  * Limit ``get_or_create`` behavior to fields specified in
    `django_get_or_create`
  * Re-raise `~django.db.IntegrityError` when `django_get_or_create`
    with multiple fields fails to lookup model using user provided
    keyword arguments
  * TypeError masked by __repr__ AttributeError when initializing
    `Maybe` with inconsistent phases

OBS-URL: https://build.opensuse.org/request/show/839483
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-factory_boy?expand=0&rev=19
2020-10-05 06:39:55 +00:00
Dominique Leuenberger
ccee309656 Accepting request 785574 from devel:languages:python
- Fix build without python2

OBS-URL: https://build.opensuse.org/request/show/785574
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-factory_boy?expand=0&rev=13
2020-03-26 23:25:39 +00:00
Tomáš Chvátal
a66a781556 - Fix build without python2
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-factory_boy?expand=0&rev=17
2020-03-16 10:32:08 +00:00
Dominique Leuenberger
a15165cacf Accepting request 749156 from devel:languages:python
- BuildRequires on %{pythons} as setuptools no longer drags it in.

OBS-URL: https://build.opensuse.org/request/show/749156
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-factory_boy?expand=0&rev=12
2019-11-22 09:25:28 +00:00
Steve Kowalik
6434f5fa67 - BuildRequires on %{pythons} as setuptools no longer drags it in.
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-factory_boy?expand=0&rev=15
2019-11-18 00:58:49 +00:00
Dominique Leuenberger
3e96aee046 Accepting request 708348 from devel:languages:python
OBS-URL: https://build.opensuse.org/request/show/708348
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-factory_boy?expand=0&rev=11
2019-06-13 20:30:40 +00:00
Tomáš Chvátal
68360073aa 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
2019-06-07 12:07:43 +00:00
Dominique Leuenberger
b522cb5e45 Accepting request 695101 from devel:languages:python
- Add patch to support django 2.2:
  * django-2.2.patch

OBS-URL: https://build.opensuse.org/request/show/695101
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-factory_boy?expand=0&rev=10
2019-04-19 16:37:51 +00:00
Tomáš Chvátal
2332ad1c61 - Add patch to support django 2.2:
* django-2.2.patch

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-factory_boy?expand=0&rev=11
2019-04-17 10:16:28 +00:00
Dominique Leuenberger
faafc79f77 Accepting request 642838 from devel:languages:python
- Update to 2.11.1:
  * Support for Django 2.1
  * Support for python 3.7
  * Various small bugfixes
- Add patch python37.patch

OBS-URL: https://build.opensuse.org/request/show/642838
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-factory_boy?expand=0&rev=9
2018-10-25 06:13:56 +00:00
Tomáš Chvátal
a2ed2f15b3 - Update to 2.11.1:
* Support for Django 2.1
  * Support for python 3.7
  * Various small bugfixes
- Add patch python37.patch

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-factory_boy?expand=0&rev=9
2018-10-18 10:23:18 +00:00
Dominique Leuenberger
cb78a2cf26 Accepting request 532235 from devel:languages:python
1

OBS-URL: https://build.opensuse.org/request/show/532235
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-factory_boy?expand=0&rev=8
2017-10-07 15:51:20 +00:00
Jan Matejek
cdf00eb4af Accepting request 532148 from home:scarabeus_iv:branches:devel:languages:python
- Update to version 2.9.2:
  * read the upstream ChangeLog for in detail list as there are
    too many changes
- Do not generate docu in the spec and make sure tests are run
- Switch to python singlespec

OBS-URL: https://build.opensuse.org/request/show/532148
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-factory_boy?expand=0&rev=7
2017-10-06 13:58:25 +00:00
Stephan Kulow
ea32d3b327 Accepting request 305661 from devel:languages:python
1

OBS-URL: https://build.opensuse.org/request/show/305661
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-factory_boy?expand=0&rev=7
2015-05-07 07:22:37 +00:00
Denisart Benjamin
e5a6730e39 Accepting request 305341 from home:benoit_monin:branches:devel:languages:python
- update to version 2.5.2
- add python-mock as BuildRequires for the tests
- add python-setuptools as BuildRequires: needed by setup.py
- build the documentation with the build_sphinx command
- pass -q to the test to avoid spamming the build log
- rename README to README.rst to follow upstream

OBS-URL: https://build.opensuse.org/request/show/305341
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-factory_boy?expand=0&rev=5
2015-05-06 23:30:02 +00:00
Stephan Kulow
0912fd5749 Accepting request 142567 from devel:languages:python
- Update to version 1.2.0:
  + Upstream provides no changelog
- Build HTML documentation

OBS-URL: https://build.opensuse.org/request/show/142567
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-factory_boy?expand=0&rev=3
2012-11-25 12:39:31 +00:00
Sascha Peilicke
0e8bf4300a - Update to version 1.2.0:
+ Upstream provides no changelog
- Build HTML documentation

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-factory_boy?expand=0&rev=3
2012-11-23 11:08:12 +00:00
Stephan Kulow
723d02e4f4 Accepting request 124463 from devel:languages:python
Please add

OBS-URL: https://build.opensuse.org/request/show/124463
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-factory_boy?expand=0&rev=1
2012-06-13 11:32:23 +00:00
Sascha Peilicke
d8bd6e7265 - Initial version
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-factory_boy?expand=0&rev=1
2012-06-11 13:12:57 +00:00