'Verify that image upload failure gets proper error message.
Arguments:
response: Response object.
error_message: Expected error message.'

def verify_error_message(self, response, error_message):

    self.assertEqual(response.status_code, 400)
    response = json.loads(response.content)
    self.assertIn('error', response)
    self.assertEqual(response['error'], error_message)
