def run(self):
     """
     Instantiate a NetworkCtrl and copy the firmware via SSH to the Router(/tmp/<firmware_name>.bin).
     """
     logging.info("%sSysupdate Firmware for Router(" + str(self.router.id) + ") ...", LoggerSetup.get_log_deep(1))
     firmware_handler = FirmwareHandler(str(ConfigManager.get_firmware_property('URL')))
     firmware = firmware_handler.get_firmware(self.router.model,
                                              str(ConfigManager.get_firmware_property('Release_Model')),
                                              bool(ConfigManager.get_firmware_property('Download_All')))
     self.router.firmware = firmware
Пример #2
0
 def run(self):
     """
     Instantiate a NetworkCtrl and copy the firmware via SSH to the Router(/tmp/<firmware_name>.bin).
     """
     logging.info(
         "%sSysupdate Firmware for Router(" + str(self.router.id) + ") ...",
         LoggerSetup.get_log_deep(1))
     firmware_handler = FirmwareHandler(
         str(ConfigManager.get_firmware_property('URL')))
     firmware = firmware_handler.get_firmware(
         self.router.model,
         str(ConfigManager.get_firmware_property('Release_Model')),
         bool(ConfigManager.get_firmware_property('Download_All')))
     self.router.firmware = firmware
Пример #3
0
 def test_firmware_property(self):
     """
     Tests the firmware config with property
     :return: Tests results
     """
     data = ConfigManager.get_firmware_property("Firmware_Version")
     self.assertEqual(True, type(data) == str, "Firmware: Wrong property")
Пример #4
0
 def test_firmware_property(self):
     """
     Tests the firmware config with property
     :return: Tests results
     """
     data = ConfigManager.get_firmware_property("Firmware_Version")
     self.assertEqual(data, "0.7.3", "Firmware: Wrong property")
Пример #5
0
 def test_firmware_property(self):
     """
     Tests the firmware config with property
     :return: Tests results
     """
     data = ConfigManager.get_firmware_property("Firmware_Version")
     self.assertEqual(data, "0.7.3",
                      "firmware_Yaml: Wrong prop from the file")