You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/api-guide/testing.md
+30Lines changed: 30 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -167,6 +167,36 @@ As usual CSRF validation will only apply to any session authenticated views. Th
167
167
168
168
---
169
169
170
+
# Test cases
171
+
172
+
REST framework includes the following test case classes, that mirror the existing Django test case classes, but use `APIClient` instead of Django's default `Client`.
173
+
174
+
*`APISimpleTestCase`
175
+
*`APITransactionTestCase`
176
+
*`APITestCase`
177
+
*`APILiveServerTestCase`
178
+
179
+
## Example
180
+
181
+
You can use any of REST framework's test case classes as you would for the regular Django test case classes. The `self.client` attribute will be an `APIClient` instance.
0 commit comments