A set of utilities to test django-rest-framework API's
Project description
django-rest-framework-supertest
An WORK IN PROGRESS set of utilities to write automated tests for APIS writen in django-rest-framework.
Motivation
The django and django-rest-framework is an powerfull set of tools to create REST API's. But, testing these API', with automated tests, are a little more complex question. Write a lot of repeated code and the difficult to made all assertions along the REST API's responses is some of these problems for our apps.
This project wants to aggregate utilities to made assertions on the responses, like APIException responses, and utilities to work with other complex REST API's concepts, like pagination and authentication.
Under the Hood
Under the hood, this is only an set of utilities and this uses some libraries to work correctly. Actually, for fake data generation we use Faker, with some small custom provider's. For assertions, we use the default django and django-rest-framework unittest
features. We provide some mixins with our own methods and some base classes
.
Roadmap
- Add Basic Faker Support
- Assertions APIExceptions
- Assert Validation Errors
- Create Faker Shortcuts
- Work with images and files
- Assert Serializer Responses
- Work with pagination
- Work with multiple types of Authentication
This is an basic roadmap for the first version and, before the first version release, some new itens can be added here.
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
Built Distribution
File details
Details for the file django_rest_framework_supertest-0.0.6.tar.gz
.
File metadata
- Download URL: django_rest_framework_supertest-0.0.6.tar.gz
- Upload date:
- Size: 23.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.9.20
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0d9bcb1f5a54afbc41220f154c83da836363eb6de9085b751f48f31eab88498a |
|
MD5 | c03f86361f89311c7c83f1fc8c67bf48 |
|
BLAKE2b-256 | 55c17d20afc085b54e8d5a4ca008889d9fcfbecbdd5dd91ced21240ddd604541 |
File details
Details for the file django_rest_framework_supertest-0.0.6-py3-none-any.whl
.
File metadata
- Download URL: django_rest_framework_supertest-0.0.6-py3-none-any.whl
- Upload date:
- Size: 36.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.9.20
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2368c74e7331b79ada21119de4d0745feb320a5f609d34b276238a4b8a8c16bc |
|
MD5 | 60f9c1a11745ad4185cad5ed8d50c3e6 |
|
BLAKE2b-256 | 7e54e30390a16d2ac6a4f9612bce488b46d174811ba046314b75d7aa2529f904 |