mirror of
				https://github.com/encode/django-rest-framework.git
				synced 2025-10-30 23:47:53 +03:00 
			
		
		
		
	Merge pull request #1203 from squidsoup/doc/testing-example
Docs: Fix for API test client example
This commit is contained in:
		
						commit
						57c41b949d
					
				|  | @ -205,10 +205,10 @@ You can use any of REST framework's test case classes as you would for the regul | |||
|             Ensure we can create a new account object. | ||||
|             """ | ||||
|             url = reverse('account-list') | ||||
|             expected = {'name': 'DabApps'} | ||||
|             data = {'name': 'DabApps'} | ||||
|             response = self.client.post(url, data, format='json') | ||||
|             self.assertEqual(response.status_code, status.HTTP_201_CREATED) | ||||
|             self.assertEqual(response.data, expected) | ||||
|             self.assertEqual(response.data, data) | ||||
| 
 | ||||
| --- | ||||
| 
 | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue
	
	Block a user