General CRUD test utils

CRUD test mixins.

class TestData(methodName='runTest')

Bases: TestCase

General test data.

Inherit it to setUp the test data.

class TestMixinAnnotations

Bases: object

Test mixins annotations.

class TestMessageMixin

Bases: object

Test message mixin.

static check_message(response: TestHttpResponse, msg: str) None

Test the response message.

class BaseTest

Bases: TestMixinAnnotations, TestMessageMixin

Base test.

class CreateTest

Bases: BaseTest

Create tests.

test_create_get_method() None

Test the item create, get method.

test_create() None

Test the item create.

test_create_by_anonymous() None

Test the item create, by anonymous.

class ListTest

Bases: BaseTest

List tests.

test_list() None

Test the item list.

test_list_anonymous() None

Test the item list, for anonymous.

class UpdateTest

Bases: BaseTest

Update tests.

test_update_get_method() None

Test the item update, get method.

test_update() None

Test the item update.

test_update_by_not_owner() None

Test the item update, by not owner.

test_update_by_anonymous() None

Test the item update, by anonymous.

class DeleteTest

Bases: BaseTest

Delete tests.

test_delete_get_method() None

Test the item delete, get method.

test_delete() None

Test the item delete.

test_delete_not_owner() None

Test the item delete, by not owner.

test_delete_anonymous() None

Test the item delete, by anonymous.

class DeleteProtectTest

Bases: DeleteTest

Test to delete protected.

test_delete_protected() None

Test the item delete protected.

class DetailTest

Bases: BaseTest

Detail tests.

test_detail() None

Test the item detail.

test_detail_for_not_owner() None

Test the item detail, for not owner.

test_detail_for_anonymous() None

Test the item detail, for anonymous.