def test_invalid_data(self):
    data = json.dumps({'title': '', 'slug': '', 'content': 'This is the content', 'annotated': {'annotations': None}})
    resp = self.client.put('/api/v1/notes/1/', data=data, content_type='application/json')
    self.assertEqual(resp.status_code, 400)
    self.assertEqual(json.loads(resp.content.decode('utf-8')), {'notes': {'slug': ['This field is required.'], 'title': ['This field is required.']}, 'annotated': {'annotations': ['This field is required.']}})
def test_invalid_data(self):
    data = json.dumps({'title': , 'slug': , 'content': 'This is the content', 'annotated': {'annotations': None}})
    resp = self.client.put('/api/v1/notes/1/', data=data, content_type='application/json')
    self.assertEqual(resp.status_code, 400)
    self.assertEqual(json.loads(resp.content.decode('utf-8')), {'notes': {'slug': ['This field is required.'], 'title': ['This field is required.']}, 'annotated': {'annotations': ['This field is required.']}})