'Ensure no cells are given the selected class when the field is empty.
Refs #4574.'

def test_calendar_no_selected_class(self):

    self.admin_login(username='super', password='secret', login_url='/')
    self.selenium.get((self.live_server_url + reverse('admin:admin_widgets_member_add')))
    self.selenium.find_element_by_id('calendarlink0').click()
    calendar0 = self.selenium.find_element_by_id('calendarin0')
    tds = calendar0.find_elements_by_tag_name('td')
    selected = [td for td in tds if (td.get_attribute('class') == 'selected')]
    self.assertEqual(len(selected), 0)
