'Scenario: Settings are only persisted when saved
Given I have set course dates
And I press the "Save" notification button
When I change fields
And I reload the page
Then I do not see the changes'

def test_settings_are_only_persisted_when_saved(self):

    self.set_course_dates()
    self.settings_page.save_changes()
    default_value_enrollment_start_date = get_input_value(self.settings_page, self.ENROLLMENT_START_TIME_CSS)
    self.settings_page.set_element_values({self.ENROLLMENT_START_TIME_CSS: self.dummy_time})
    self.settings_page.refresh_and_wait_for_load()
    self.ensure_input_fields_are_loaded()
    css_selectors = [self.COURSE_START_DATE_CSS, self.COURSE_END_DATE_CSS, self.ENROLLMENT_START_DATE_CSS, self.ENROLLMENT_END_DATE_CSS, self.ENROLLMENT_START_TIME_CSS]
    expected_values = [self.course_start_date, self.course_end_date, self.enrollment_start_date, self.enrollment_end_date, default_value_enrollment_start_date]
    self.assertEqual([get_input_value(self.settings_page, css_selector) for css_selector in css_selectors], expected_values)
