'Export failure helper method.'

def _verify_export_failure(self, expected_text):

    resp = self.client.post(self.url)
    self.assertEquals(resp.status_code, 200)
    resp = self.client.get(self.status_url)
    self.assertEquals(resp.status_code, 200)
    result = json.loads(resp.content)
    self.assertNotIn('ExportOutput', result)
    self.assertIn('ExportError', result)
    error = result['ExportError']
    self.assertIn('Unable    to    create    xml    for    module', error['raw_error_msg'])
    self.assertIn(expected_text, error['edit_unit_url'])
