summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
Diffstat (limited to 'docs')
-rw-r--r--docs/changelog.rst1
-rw-r--r--docs/orms.rst23
2 files changed, 24 insertions, 0 deletions
diff --git a/docs/changelog.rst b/docs/changelog.rst
index 75f1c41..0367246 100644
--- a/docs/changelog.rst
+++ b/docs/changelog.rst
@@ -15,6 +15,7 @@ ChangeLog
- The :class:`~factory.django.DjangoModelFactory` now supports the ``FACTORY_FOR = 'myapp.MyModel'``
syntax, making it easier to shove all factories in a single module (:issue:`66`).
+ - Adding factory support for mongoengine with :class:`~factory.mongoengine.MongoEngineFactory`.
.. _v2.1.2:
diff --git a/docs/orms.rst b/docs/orms.rst
index 8215fe6..74c5c62 100644
--- a/docs/orms.rst
+++ b/docs/orms.rst
@@ -163,6 +163,29 @@ factory_boy supports `Mogo`_-style models, through the :class:`MogoFactory` clas
* :func:`~factory.Factory.create()` builds an instance through ``new()`` then
saves it.
+
+MongoEngine
+----
+
+.. currentmodule:: factory.mongoengine
+
+factory_boy supports `MongoEngine`_-style models, through the :class:`MongoEngineFactory` class.
+
+`mongoengine`_ is a wrapper around the ``pymongo`` library for MongoDB.
+
+.. _mongoengine:: http://mongoengine.org/
+
+.. class:: MongoEngineFactory(factory.Factory)
+
+ Dedicated class for `MongoEngine`_ models.
+
+ This class provides the following features:
+
+ * :func:`~factory.Factory.build()` calls a model's ``__init__`` method
+ * :func:`~factory.Factory.create()` builds an instance through ``__init__`` then
+ saves it.
+
+
SQLAlchemy
----------