'Scenario: User can view all notes by recent activity.
Given I have a course with 5 notes
When I open Notes page
Then I see 5 notes sorted by the updated date
And I see correct content in the notes
And an event has fired indicating that the Recent Activity view was selected'

def test_recent_activity_view(self):

    self._add_default_notes()
    self.notes_page.visit()
    notes = self.notes_page.notes
    self.assertEqual(len(notes), 5)
    self.assertNoteContent(notes[0], quote=u'Annotate    this', text=u'Fifth    note', unit_name='Test    Unit    1', time_updated='Jan    01,    2015    at    01:01    UTC')
    self.assertNoteContent(notes[1], text=u'Fourth    note', unit_name='Test    Unit    3', time_updated='Jan    01,    2014    at    01:01    UTC', tags=['review'])
    self.assertNoteContent(notes[2], quote='Annotate    this', text=u'Third    note', unit_name='Test    Unit    1', time_updated='Jan    01,    2013    at    01:01    UTC', tags=['Cool', 'TODO'])
    self.assertNoteContent(notes[3], quote=u'Annotate    this', unit_name='Test    Unit    2', time_updated='Jan    01,    2012    at    01:01    UTC', tags=['Review', 'cool'])
    self.assertNoteContent(notes[4], quote=u'Annotate    this', text=u'First    note', unit_name='Test    Unit    4', time_updated='Jan    01,    2011    at    01:01    UTC')
    self.assert_viewed_event()
