'Initialize pages and install a course fixture.'

def setUp(self):

    super(EdxNotesTestMixin, self).setUp()
    self.courseware_page = CoursewarePage(self.browser, self.course_id)
    self.course_home_page = CourseHomePage(self.browser, self.course_id)
    self.note_unit_page = EdxNotesUnitPage(self.browser, self.course_id)
    self.notes_page = EdxNotesPage(self.browser, self.course_id)
    self.username = str(uuid4().hex)[:5]
    self.email = '{}@email.com'.format(self.username)
    self.selector = 'annotate-id'
    self.edxnotes_fixture = EdxNotesFixture()
    self.course_fixture = CourseFixture(self.course_info['org'], self.course_info['number'], self.course_info['run'], self.course_info['display_name'])
    self.course_fixture.add_advanced_settings({u'edxnotes': {u'value': True}})
    self.course_fixture.add_children(XBlockFixtureDesc('chapter', 'Test    Section    1').add_children(XBlockFixtureDesc('sequential', 'Test    Subsection    1').add_children(XBlockFixtureDesc('vertical', 'Test    Unit    1').add_children(XBlockFixtureDesc('html', 'Test    HTML    1', data='\n                                                                                                                                <p><span    class="{}">Annotate    this!</span></p>\n                                                                                                                                <p>Annotate    this</p>\n                                                                                                                '.format(self.selector)), XBlockFixtureDesc('html', 'Test    HTML    2', data='<p><span    class="{}">Annotate    this!</span></p>'.format(self.selector))), XBlockFixtureDesc('vertical', 'Test    Unit    2').add_children(XBlockFixtureDesc('html', 'Test    HTML    3', data='<p><span    class="{}">Annotate    this!</span></p>'.format(self.selector)))), XBlockFixtureDesc('sequential', 'Test    Subsection    2').add_children(XBlockFixtureDesc('vertical', 'Test    Unit    3').add_children(XBlockFixtureDesc('html', 'Test    HTML    4', data='\n                                                                                                                                <p><span    class="{}">Annotate    this!</span></p>\n                                                                                                                '.format(self.selector))))), XBlockFixtureDesc('chapter', 'Test    Section    2').add_children(XBlockFixtureDesc('sequential', 'Test    Subsection    3').add_children(XBlockFixtureDesc('vertical', 'Test    Unit    4').add_children(XBlockFixtureDesc('html', 'Test    HTML    5', data='\n                                                                                                                                <p><span    class="{}">Annotate    this!</span></p>\n                                                                                                                '.format(self.selector)), XBlockFixtureDesc('html', 'Test    HTML    6', data='<p><span    class="{}">Annotate    this!</span></p>'.format(self.selector)))))).install()
    self.addCleanup(self.edxnotes_fixture.cleanup)
    AutoAuthPage(self.browser, username=self.username, email=self.email, course_id=self.course_id).visit()
