'Verify that the course start date is included on the course outline page.'

def test_start_date_on_page(self):

    def _get_release_date(response):
        'Return    the    release    date    from    the    course    page'
        parsed_html = lxml.html.fromstring(response.content)
        return parsed_html.find_class('course-status')[0].find_class('status-release-value')[0].text_content()
    def _assert_settings_link_present(response):
        "\n                                                Asserts    there's    a    course    settings    link    on    the    course    page    by    the    course    release    date.\n                                                "
        parsed_html = lxml.html.fromstring(response.content)
        settings_link = parsed_html.find_class('course-status')[0].find_class('action-edit')[0].find('a')
        self.assertIsNotNone(settings_link)
        self.assertEqual(settings_link.get('href'), reverse_course_url('settings_handler', self.course.id))
    outline_url = reverse_course_url('course_handler', self.course.id)
    response = self.client.get(outline_url, {}, HTTP_ACCEPT='text/html')
    self.assertEqual(_get_release_date(response), 'Unscheduled')
    _assert_settings_link_present(response)
    self.course.start = datetime.datetime(2014, 1, 1, tzinfo=pytz.utc)
    modulestore().update_item(self.course, ModuleStoreEnum.UserID.test)
    response = self.client.get(outline_url, {}, HTTP_ACCEPT='text/html')
    self.assertEqual(_get_release_date(response), get_default_time_display(self.course.start))
    _assert_settings_link_present(response)
