From 4e149f904cc8e0e61dd8bcc190680414fdf61767 Mon Sep 17 00:00:00 2001 From: Raphaël Barrois Date: Mon, 11 Mar 2013 22:19:51 +0100 Subject: doc: Fix rst. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Raphaël Barrois --- docs/reference.rst | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) (limited to 'docs') diff --git a/docs/reference.rst b/docs/reference.rst index 0bb0d74..e1f763c 100644 --- a/docs/reference.rst +++ b/docs/reference.rst @@ -1072,7 +1072,7 @@ PostGenerationMethodCall The default set of unnamed arguments to pass to the method given in :attr:`method_name` - .. attrinbute:: kwargs + .. attribute:: kwargs The default set of keyword arguments to pass to the method given in :attr:`method_name` @@ -1120,21 +1120,23 @@ factory during instantiation. >>> other_u.check_password('different') True -.. note:: For Django models, unless the object method called by - :class:`PostGenerationMethodCall` saves the object back to the - database, we will have to explicitly remember to save the object back - if we performed a ``create()``. +.. note:: - .. code-block:: pycon + For Django models, unless the object method called by + :class:`PostGenerationMethodCall` saves the object back to the + database, we will have to explicitly remember to save the object back + if we performed a ``create()``. + + .. code-block:: pycon >>> u = UserFactory.create() # u.password has not been saved back to the database >>> u.save() # we must remember to do it ourselves - We can avoid this by subclassing from :class:`DjangoModelFactory`, - instead, e.g., + We can avoid this by subclassing from :class:`DjangoModelFactory`, + instead, e.g., - .. code-block:: python + .. code-block:: python class UserFactory(factory.DjangoModelFactory): FACTORY_FOR = User -- cgit v1.2.3