Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Where are the Assertion Methods list from Django TestCase? [closed]

I googled to find the assert methods list. But it seems like this documentation is very well hidden. Does anyone know where it is?

like image 664
btk Avatar asked Jul 20 '11 19:07

btk


People also ask

What is SimpleTestCase?

SimpleTestCase is the simplest one. It provides the basic features of unittest. TestCase plus some Django extras. It blocks database access by default, because it doesn't do anything to isolate changes you would make there. You should use it for testing components that don't need the database.

What is client in Django test?

The test client. The test client is a Python class that acts as a dummy web browser, allowing you to test your views and interact with your Django-powered application programmatically.

What is self client in Django?

self. client , is the built-in Django test client. This isn't a real browser, and doesn't even make real requests. It just constructs a Django HttpRequest object and passes it through the request/response process - middleware, URL resolver, view, template - and returns whatever Django produces.


1 Answers

It just uses the standard python unittest, http://docs.python.org/library/unittest.html#assert-methods, extended with Django-specific asserts which can be found here.

like image 76
kcbanner Avatar answered Oct 19 '22 18:10

kcbanner