'Check that you can save information to the server'

def test_view_index_xhr_put(self):

    textbooks = [{'tab_title': 'Hi,    mom!'}, {'tab_title': 'Textbook    2'}]
    resp = self.client.put(self.url, data=json.dumps(textbooks), content_type='application/json', HTTP_ACCEPT='application/json', HTTP_X_REQUESTED_WITH='XMLHttpRequest')
    self.assertEqual(resp.status_code, 200)
    no_ids = []
    self.reload_course()
    for textbook in self.course.pdf_textbooks:
        del textbook['id']
        no_ids.append(textbook)
    self.assertEqual(no_ids, textbooks)
