~mihirsoni/ubuntu-calendar-app/dateSelectNewEventTest

« back to all changes in this revision

Viewing changes to tests/autopilot/calendar_app/tests/test_new_event.py

  • Committer: Mihir Soni
  • Date: 2014-10-23 22:44:56 UTC
  • Revision ID: mihirsoni.123@gmail.com-20141023224456-2j0wago6tbis6eyp
Date select while creating new event

Show diffs side-by-side

added added

removed removed

Lines of Context:
49
49
        test_event = data.Event.make_unique()
50
50
        new_event_page = self.app.main_view.go_to_new_event()
51
51
        new_event_page.add_event(test_event)
52
 
 
53
 
        self.assertThat(lambda: self._event_exists(test_event.name),
54
 
                        Eventually(Equals(True)))
55
 
 
56
52
        return test_event
57
53
 
58
54
    def _edit_event(self, event_name):
121
117
        self.assertThat(lambda: self._event_exists(test_event.name),
122
118
                        Eventually(Equals(False)))
123
119
 
 
120
    def test_add_new_event_next_day(self):
 
121
        test_event = self._add_event()
 
122
        self.addCleanup(self._try_delete_event, edited_event.name)
 
123
        day_view = self.app.main_view.go_to_day_view()
 
124
        self.app.main_view.swipe_view(1, day_view)
 
125
        event_details_page = day_view.open_event(test_event.name)
 
126
 
 
127
        self.assertEqual(test_event,
 
128
                         event_details_page.get_event_information())
 
129
 
124
130
    def test_edit_event_with_default_values(self):
125
131
        """Test editing an event change unique values of an event."""
126
132