Skip to main content

UNKNOWN

Project description

Test helpers, mostly geared around the database. Tested on Django 1.2.

Install

pip install django-test-helpers

Usage

Create a temporary database:

from testhelpers.dbmanager import TemporaryDatabase

with TemporaryDatabase(fixtures=['myfixture.json'], db_prefix='test'):
    # do some stuff
    pass

Run some commands in transactional isolation:

from testhelpers.dbmanager import Transactionless

with Transactionless(fixtures=['myfixture.json']):
    # do some stuff
    pass

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django-test-helpers-0.1.0.tar.gz (5.0 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page