Skip to main content

Simple tests tools to make testing faster and easier.

Project description

https://badge.fury.io/py/django-test-tools.svg https://travis-ci.org/luiscberrocal/django-test-tools.svg?branch=master https://codecov.io/gh/luiscberrocal/django-test-tools/branch/master/graph/badge.svg Code Health

Simple tests tools to make testing faster and easier.

Supports Python 3.4, 3.5, 3.5 with Django 1.10.7 and 1.11.x.

Documentation

The full documentation is at https://django-test-tools.readthedocs.io.

Quickstart

Install Django Test Tools:

pip install django-test-tools

Add it to your INSTALLED_APPS:

INSTALLED_APPS = (
    ...
    'django_test_tools.apps.DjangoTestToolsConfig',
    ...
)

Add Django Test Tools’s URL patterns:

from django_test_tools import urls as django_test_tools_urls


urlpatterns = [
    ...
    url(r'^', include(django_test_tools_urls)),
    ...
]

Features

Factory Generator

$  $ python manage.py generate_factories project.app

Model Test Case Generator

$  $ python manage.py generate_model_test_cases project.app

Serializer Generator

$ python manage.py generate_serializers project.app -s ModelSerializer

Running Tests

Does the code actually work?

source <YOURVIRTUALENV>/bin/activate
(myenv) $ pip install tox
(myenv) $ tox

Builds

Create a release using git-flow

Run bumpversion

$ bumpversion minor

Instead of minor you could also use major o patch depending on the level of the release.

python setup.py sdist bdist_wheel

python setup.py register -r pypitest

python setup.py sdist upload -r pypitest

To publish to pypi run:

python setup.py sdist upload -r pypi

Credits

Tools used in rendering this package:

History

0.1.0 (2017-04-26)

  • First release on PyPI.

Project details


Release history Release notifications | RSS feed

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-tools-0.9.0.tar.gz (23.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

django_test_tools-0.9.0-py2.py3-none-any.whl (32.3 kB view details)

Uploaded Python 2Python 3

File details

Details for the file django-test-tools-0.9.0.tar.gz.

File metadata

File hashes

Hashes for django-test-tools-0.9.0.tar.gz
Algorithm Hash digest
SHA256 de7844d3a5fdf13eea0c95e4636b5b1d2821156670113180712306c4f8a121af
MD5 cc28f9ab8f7021eb21ebe2788f6e6c45
BLAKE2b-256 57931175d7075c7d756189924a8ce3057a699de802e1c068387439abdfaa09bb

See more details on using hashes here.

File details

Details for the file django_test_tools-0.9.0-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for django_test_tools-0.9.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 79148a89e8eaef4e228822a185fbb36ac1b2bcee5df8feb6b8a6afc55ea334e9
MD5 820590e77ec37ea02835e402bb76ac63
BLAKE2b-256 65960b851d4c0cde15464142140a9497e39aa5c6824987cacb8ee512e73e320b

See more details on using hashes here.

Supported by

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