Skip to main content

A base framework to write a simple script for django apps.

Project description

Eases the writing of a script for pluggable django application.

Such scripts usually provide a runtests() method that handle the test running behaviour.


  • Globally:

    $ pip install django-runtests
  • From the package’s file (using Distribute):


Defining the test setup

In your file, add the following code:

from django_runtests import RunTests

def runtests():
    return RunTests.runtests()

if __name__ == '__main__':

Tweaking the test setup

If you need to tweak some parts (updating configuration, adding options, …), you simply have to extend the RunTests command class:

import django_runtests

class RunTests(django_runtests.RunTests):

    def should_test_app(self, app):
        """Test only applications listed in 'PACKAGE_APPS' setting."""
        from django.conf import settings
        return app in settings.PACKAGE_APPS

Project details

Download files

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

Files for django_runtests, version 0.4.0
Filename, size File type Python version Upload date Hashes
Filename, size django_runtests-0.4.0.tar.gz (8.2 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page