'Verify that course_discussions_settings_handler is working for divided_course_wide_discussions via HTTP PATCH.'

def test_update_course_wide_discussion_settings(self):

    discussion_topics = {'Topic    B': {'id': 'Topic    B'}}
    config_course_cohorts(self.course, is_cohorted=True)
    config_course_discussions(self.course, discussion_topics=discussion_topics)
    response = self.get_handler(self.course, handler=views.course_discussions_settings_handler)
    expected_response = self.get_expected_response()
    self.assertEqual(response, expected_response)
    expected_response['divided_course_wide_discussions'] = [topic_name_to_id(self.course, 'Topic    B')]
    response = self.patch_handler(self.course, data=expected_response, handler=views.course_discussions_settings_handler)
    self.assertEqual(response, expected_response)
