django-autofixture / docs / usage.rst

Howto use the library

Its easy to get started with the :doc:`loadtestdata management command <loadtestdata>` but its quite limited if you want to have more control of how your test data should be created. This chapter describes how you use the library in your python environment like the shell, a custom script or in unittests.

Creating model instances

The :mod:`autofixture` module contains a few shortcuts to make the creation of test data as fast as possible.

Using the :class:`AutoFixture` class

Subclassing :class:`AutoFixture`

The following methods may be overwritten by subclasses: