Exemple #1
0
 def test_4_AllSchedules(self):
     l_schedules = scheduleXml.read_schedules_xml(self.m_pyhouse_obj)
     l_xml, l_count = scheduleXml.write_schedules_xml(l_schedules)
     # print(PrettyFormatAny.form(l_xml, 'B2-4-A - All Interfaces'))
     self.assertEqual(l_count, len(l_schedules))
     self.assertEqual(l_xml[0].attrib['Name'], TESTING_SCHEDULE_NAME_0)
     self.assertEqual(l_xml[0][1].text, TESTING_SCHEDULE_DOW_0)
     self.assertEqual(l_xml[1].attrib['Name'], TESTING_SCHEDULE_NAME_1)
     self.assertEqual(l_xml[1][1].text, TESTING_SCHEDULE_DOW_1)
     self.assertEqual(l_xml[2].attrib['Name'], TESTING_SCHEDULE_NAME_2)
     self.assertEqual(l_xml[2][1].text, TESTING_SCHEDULE_DOW_2)
     self.assertEqual(l_xml[3].attrib['Name'], TESTING_SCHEDULE_NAME_3)
     self.assertEqual(l_xml[3][1].text, TESTING_SCHEDULE_DOW_3)
Exemple #2
0
 def test_04_AllSchedules(self):
     l_schedules = scheduleXml.read_schedules_xml(self.m_pyhouse_obj)
     l_xml = scheduleXml.write_schedules_xml(l_schedules)
Exemple #3
0
 def SaveXml(self, p_xml):
     l_xml, l_count = scheduleXml.write_schedules_xml(
         self.m_pyhouse_obj.House.Schedules)
     p_xml.append(l_xml)
     LOG.info('Saved {} Schedules XML.'.format(l_count))
     return l_xml  # for testing
Exemple #4
0
 def SaveXml(self, p_xml):
     l_xml, l_count = scheduleXml.write_schedules_xml(self.m_pyhouse_obj.House.Schedules)
     p_xml.append(l_xml)
     LOG.info('Saved {} Schedules XML.'.format(l_count))
     return l_xml  # for testing