def test_ath_6436_switch_not_in_factory_default_configuration_registered_to_athena_it_appears_as_unprovisioned_device(
            self):
        firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
        device_management_page = self.LeftPanel.go_to_device_management()
        device_management_page.unassign_switch_license("Switch_1")
        monitoring_switch_page = self.LeftPanel.go_to_monitoring_switches_page(
        )
        monitoring_switch_page.delete_switch_device_based_on_ip("Switch_1")
        DeviceLibrary.factoryReset("Switch_1")
        firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
        device_management_page = self.LeftPanel.go_to_device_management()
        device_management_page.add_switch_and_assign_license("Switch_1")
        DeviceLibrary.connect_device_to_server("Switch_1")
        import time
        time.sleep(120)
        self.browser.refresh()

        inner_left_panel = self.TopPanel.click_slider_icon()
        manage_group_page = inner_left_panel.manage_group()
        manage_group_page.group_sidebar_close_icon.click()
        manage_group_page.move_unprovisioned_device('Switch_1', 'New Group',
                                                    'switch')

        inner_left_panel.manage_group()
        manage_group_page.move_device_to_group('default', 'Switch_1')

        inner_left_panel.manage_group()
        manage_group_page.delete_group('switch')
	def test_ath_11302_check_non_default_values_cpu_util(self):
		myDevice = Device.getDeviceObject("IAP_1")
		vlan_id = myDevice.get("vlan")
		conf = self.config.config_vars
		system_page = self.LeftPanel.go_to_system_page()
		system_page.set_new_vc_name("IAP_1",conf.vc_name)
		system_page.set_new_vc_ip("IAP_1",conf.ip_add)
		system_page.set_non_default_values_cpu_util("IAP_1")
		system_page._save_settings()
		time.sleep(10)
		system_page.assert_system_page_vc_field_values("IAP_1","sh ru | inc name",conf.vc_name)
		system_page.assert_system_page_vc_field_values("IAP_1","sh ru | inc virtual",conf.ip_add)
		system_page.assert_system_page_vc_field_values("IAP_1","sh ru | inc time","Pacific-Time -07")
		system_page.assert_system_page_vc_field_values("IAP_1","sh ru | inc ntp",conf.ntp_server)
		system_page.assert_system_page_vc_field_values("IAP_1","sh ru | inc band","5ghz")
		system_page.assert_system_page_vc_field_values("IAP_1","sh ru | inc vlan",vlan_id)
		system_page.assert_system_page_vc_field_values("IAP_1","sh ru | inc cpu","dynamic-cpu-mgmt enable")
		
		time.sleep(10)
		DeviceLibrary.factoryReset("IAP_1")
		time.sleep(10)
		DeviceLibrary.getPrompt("IAP_1")
		DeviceLibrary.reconnect("IAP_1")
		time.sleep(90)
		inner_left_panel = self.TopPanel.click_slider_icon()
		inner_left_panel.click_expand_default_group_icon()
		inner_left_panel.select_vc("IAP_1")
		inner_left_panel.select_country_code(self.config.config_vars.country_india)
		# system_page.setting_original_vc_name("IAP_1",conf.vc_name) // After factory_reset, automatically take default name on system page
		# system_page.setting_original_vc_ip("IAP_1",conf.ip_add) // After factory_reset, automatically take default ip on system page
		system_page.set_cpu_util_default_values()
 def test_ath_6436_switch_not_in_factory_default_configuration_registered_to_athena_it_appears_as_unprovisioned_device(self):
     firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
     device_management_page = self.LeftPanel.go_to_device_management()
     device_management_page.unassign_switch_license("Switch_1")
     monitoring_switch_page = self.LeftPanel.go_to_monitoring_switches_page()
     monitoring_switch_page.delete_switch_device_based_on_ip("Switch_1")
     DeviceLibrary.factoryReset("Switch_1")
     firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
     device_management_page = self.LeftPanel.go_to_device_management()
     device_management_page.add_switch_and_assign_license("Switch_1")
     DeviceLibrary.connect_device_to_server("Switch_1")
     import time
     time.sleep(120)
     self.browser.refresh()
     
     inner_left_panel = self.TopPanel.click_slider_icon()
     manage_group_page = inner_left_panel.manage_group()
     manage_group_page.group_sidebar_close_icon.click()
     manage_group_page.move_unprovisioned_device('Switch_1','New Group','switch')
     
     inner_left_panel.manage_group()
     manage_group_page.move_device_to_group('default','Switch_1')
     
     inner_left_panel.manage_group()
     manage_group_page.delete_group('switch')
 def test_ath_11101_radio_config_unprovisioned_iap(self):
     conf = self.config.config_vars
     inner_left_panel = self.TopPanel.click_slider_icon()
     inner_left_panel.click_all_groups_label()
     device_mgmt = self.LeftPanel.go_to_device_management()
     device_mgmt.get_and_search_mac_address()
     device_mgmt.select_virtual_controller(device_mgmt.device_selector_1)
     device_mgmt.select_assign_group()
     device_mgmt.all_group.click()
     device_mgmt.click_assign()
     logger.debug('DeviceManagement: Clicking on ok button')
     device_mgmt.ok_button.click()
     device_mgmt.assert_group_name(conf.unprovisioned)
     time.sleep(10)
     DeviceLibrary.factoryReset('IAP_1')
     time.sleep(10)
     inner_left_panel = self.TopPanel.click_slider_icon()
     inner_left_panel.select_unprovision_iap()
     inner_left_panel.assert_unprovisioned_alert_popup()
     rf_page = self.LeftPanel.go_to_rf_page()
     rf_page.open_radio_accordion()
     import os
     os.environ['device'] = "IAP_1"
     self.take_s1_snapshot("show_radio_config")
     rf_page.set_legacy_only_24ghz(conf.legacy_only_enabled)
     rf_page.set_dropdown_11d_11h_24ghz(conf.band_802_enabled)
     rf_page.set_beacon_interval_24ghz(conf.new_beacon_interval_value1)
     rf_page.set_interface_immunity_24ghz(conf.interface_immunity_1)
     rf_page.set_channel_switch_announce_24ghz(
         conf.new_channel_switch_announce_3)
     rf_page.set_background_spectrum_24ghz(
         conf.new_background_spectrum_24ghz_value)
     rf_page.set_legacy_only_5ghz(conf.legacy_only_enabled)
     rf_page.set_dropdown_11d_11h_5ghz(conf.band_802_enabled)
     rf_page.set_beacon_interval_5ghz(conf.sixty)
     rf_page.set_interface_immunity_5ghz(conf.interface_immunity_5)
     rf_page.set_channel_switch_announce_5ghz(
         conf.new_channel_switch_announce_5)
     rf_page.set_background_spectrum_5ghz(
         conf.new_background_spectrum_5ghz_value)
     rf_page.save_changes()
     time.sleep(20)
     import os
     os.environ['device'] = "IAP_1"
     self.take_s2_snapshot("show_radio_config")
     rf_page.set_2ghz_band_values_to_default()
     rf_page.set_5ghz_band_values_to_default()
     rf_page.save_changes()
     os.environ['device'] = "IAP_1"
     self.take_s3_snapshot("show_radio_config")
     create_group_page = inner_left_panel.click_configuration_page_new_group_button(
     )
     create_group_page.create_empty_group1('group1')
     import os
     os.environ['device'] = "IAP_1"
     self.assert_s1_s2_diff(0)
     os.environ['device'] = "IAP_1"
     self.assert_s1_s3_diff()
     self.clear()
 def test_ath_11101_radio_config_unprovisioned_iap(self):
     conf = self.config.config_vars
     inner_left_panel = self.TopPanel.click_slider_icon()
     inner_left_panel.click_all_groups_label()
     device_mgmt = self.LeftPanel.go_to_device_management()
     device_mgmt.get_and_search_mac_address()
     device_mgmt.select_virtual_controller(device_mgmt.device_selector_1)
     device_mgmt.select_assign_group()
     device_mgmt.all_group.click()
     device_mgmt.click_assign()
     logger.debug('DeviceManagement: Clicking on ok button')
     device_mgmt.ok_button.click()
     device_mgmt.assert_group_name(conf.unprovisioned)
     time.sleep(10)
     DeviceLibrary.factoryReset('IAP_1')
     time.sleep(10)
     inner_left_panel = self.TopPanel.click_slider_icon()
     inner_left_panel.select_unprovision_iap()
     inner_left_panel.assert_unprovisioned_alert_popup()
     rf_page = self.LeftPanel.go_to_rf_page()
     rf_page.open_radio_accordion()
     import os
     os.environ['device'] = "IAP_1"
     self.take_s1_snapshot("show_radio_config")
     rf_page.set_legacy_only_24ghz(conf.legacy_only_enabled)
     rf_page.set_dropdown_11d_11h_24ghz(conf.band_802_enabled)
     rf_page.set_beacon_interval_24ghz(conf.new_beacon_interval_value1)
     rf_page.set_interface_immunity_24ghz(conf.interface_immunity_1)
     rf_page.set_channel_switch_announce_24ghz(conf.new_channel_switch_announce_3)
     rf_page.set_background_spectrum_24ghz(conf.new_background_spectrum_24ghz_value)
     rf_page.set_legacy_only_5ghz(conf.legacy_only_enabled)
     rf_page.set_dropdown_11d_11h_5ghz(conf.band_802_enabled)
     rf_page.set_beacon_interval_5ghz(conf.sixty)
     rf_page.set_interface_immunity_5ghz(conf.interface_immunity_5)
     rf_page.set_channel_switch_announce_5ghz(conf.new_channel_switch_announce_5)
     rf_page.set_background_spectrum_5ghz(conf.new_background_spectrum_5ghz_value)
     rf_page.save_changes()
     time.sleep(20)
     import os
     os.environ['device'] = "IAP_1"
     self.take_s2_snapshot("show_radio_config")
     rf_page.set_2ghz_band_values_to_default()
     rf_page.set_5ghz_band_values_to_default()
     rf_page.save_changes()
     os.environ['device'] = "IAP_1"
     self.take_s3_snapshot("show_radio_config")
     create_group_page = inner_left_panel.click_configuration_page_new_group_button()
     create_group_page.create_empty_group1('group1')
     import os
     os.environ['device'] = "IAP_1"
     self.assert_s1_s2_diff(0)
     os.environ['device'] = "IAP_1"
     self.assert_s1_s3_diff()
     self.clear()
    def test_ath_6440_move_single_switch_from_one_group_to_another_group_having_a_switch(
            self):
        firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
        device_management_page = self.LeftPanel.go_to_device_management()

        device_management_page.unassign_switch_license("Switch_1")
        monitoring_switch_page = self.LeftPanel.go_to_monitoring_switches_page(
        )
        monitoring_switch_page.delete_switch_device_based_on_ip("Switch_1")
        DeviceLibrary.factoryReset("Switch_1")
        firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
        device_management_page = self.LeftPanel.go_to_device_management()
        device_management_page.add_switch_and_assign_license("Switch_1")
        DeviceLibrary.connect_device_to_server("Switch_1")

        device_management_page.unassign_switch_license("Switch_2")
        monitoring_switch_page = self.LeftPanel.go_to_monitoring_switches_page(
        )
        monitoring_switch_page.delete_switch_device_based_on_ip("Switch_2")
        DeviceLibrary.factoryReset("Switch_2")
        import time
        time.sleep(120)
        firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
        device_management_page = self.LeftPanel.go_to_device_management()
        device_management_page.add_switch_and_assign_license("Switch_2")
        try:
            DeviceLibrary.connect_device_to_server("Switch_2")
        except:
            pass
        import time
        time.sleep(120)
        self.browser.refresh()
        time.sleep(60)

        inner_left_panel = self.TopPanel.click_slider_icon()
        manage_group_page = inner_left_panel.manage_group()
        manage_group_page.group_sidebar_close_icon.click()
        manage_group_page.move_unprovisioned_device('Switch_1', 'New Group',
                                                    'group1')
        manage_group_page.move_unprovisioned_device('Switch_2', 'New Group',
                                                    'group2')

        inner_left_panel.manage_group()
        manage_group_page.move_device_to_group('group1', 'Switch_2')

        inner_left_panel.manage_group()
        manage_group_page.move_device_to_group('default', 'Switch_1')
        inner_left_panel.manage_group()
        manage_group_page.move_device_to_group('default', 'Switch_2')

        manage_group = inner_left_panel.manage_group()
        manage_group.delete_group('group1')
        manage_group = inner_left_panel.manage_group()
        manage_group.delete_group('group2')
Esempio n. 7
0
    def test_ath_10984_attach_iap_with_deny_inter_user_bridging_and_deny_local_routing_options(
            self):
        conf = self.config.config_vars
        DeviceLibrary.disconnect_device_from_server('IAP_2')
        DeviceLibrary.factoryReset('IAP_2')
        time.sleep(350)
        DeviceLibrary.configure_deny_inter_user_bridging_and_deny_local_routing(
            'IAP_2')
        DeviceLibrary.connect_device_to_server('IAP_2')
        time.sleep(400)
        self.browser.refresh()
        inner_left_panel = self.TopPanel.click_slider_icon()
        inner_left_panel.select_unprovision_iap()
        manage_group_page = inner_left_panel.click_configuration_page_existing_group_button(
        )
        manage_group_page.move_unprovisioned_device('IAP_2',
                                                    group_name='group1')
        time.sleep(20)
        DeviceLibrary.reconnect('IAP_2')
        time.sleep(400)
        self.assert_running_config_include_deny('IAP_2',
                                                'deny-inter-user-bridging')
        time.sleep(20)
        self.assert_running_config_include_deny('IAP_2', 'deny-local-routing')
        time.sleep(20)
        DeviceLibrary.disconnect_device_from_server('IAP_2')
        DeviceLibrary.factoryReset('IAP_2')
        time.sleep(350)
        DeviceLibrary.configure_deny_inter_user_bridging_and_deny_local_routing(
            'IAP_2')
        DeviceLibrary.connect_device_to_server('IAP_2')
        time.sleep(400)
        self.browser.refresh()
        inner_left_panel = self.TopPanel.click_slider_icon()
        inner_left_panel.select_unprovision_iap()
        create_group_page = inner_left_panel.click_configuration_page_new_group_button(
        )
        create_group_page.move_unprovisional_device_to_new_group('group2')
        time.sleep(20)
        DeviceLibrary.reconnect('IAP_2')
        time.sleep(400)
        self.assert_running_config_include_deny('IAP_2',
                                                'deny-inter-user-bridging',
                                                exists=True)
        time.sleep(20)
        self.assert_running_config_include_deny('IAP_2',
                                                'deny-local-routing',
                                                exists=True)

        self.browser.refresh()
        inner_left_panel = self.TopPanel.click_slider_icon()
        manage_group_page = inner_left_panel.manage_group()
        manage_group_page.move_vc_to_group('group2', 'IAP_1')
        time.sleep(20)
 def test_ath_6520_verify_unprovisioned_switches_are_seen_in_selection_while_creating_new_group(self):
     firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
     device_management_page = self.LeftPanel.go_to_device_management()
     device_management_page.unassign_switch_license("Switch_1")
     monitoring_switch_page = self.LeftPanel.go_to_monitoring_switches_page()
     monitoring_switch_page.delete_switch_device_based_on_ip("Switch_1")
     DeviceLibrary.factoryReset("Switch_1")
     firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
     device_management_page = self.LeftPanel.go_to_device_management()
     device_management_page.add_switch_and_assign_license("Switch_1")
     DeviceLibrary.connect_device_to_server("Switch_1")
     inner_left_panel = self.TopPanel.click_slider_icon()
     inner_left_panel.assert_device_in_group('Switch_1','Unprovisioned')
    def test_ath_6440_move_single_switch_from_one_group_to_another_group_having_a_switch(self):
        firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
        device_management_page = self.LeftPanel.go_to_device_management()
        
        device_management_page.unassign_switch_license("Switch_1")
        monitoring_switch_page = self.LeftPanel.go_to_monitoring_switches_page()
        monitoring_switch_page.delete_switch_device_based_on_ip("Switch_1")
        DeviceLibrary.factoryReset("Switch_1")
        firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
        device_management_page = self.LeftPanel.go_to_device_management()
        device_management_page.add_switch_and_assign_license("Switch_1")
        DeviceLibrary.connect_device_to_server("Switch_1")

        device_management_page.unassign_switch_license("Switch_2")
        monitoring_switch_page = self.LeftPanel.go_to_monitoring_switches_page()
        monitoring_switch_page.delete_switch_device_based_on_ip("Switch_2")
        DeviceLibrary.factoryReset("Switch_2")
        import time
        time.sleep(120)
        firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
        device_management_page = self.LeftPanel.go_to_device_management()
        device_management_page.add_switch_and_assign_license("Switch_2")
        try:
            DeviceLibrary.connect_device_to_server("Switch_2")
        except:
            pass
        import time
        time.sleep(120)
        self.browser.refresh()
        time.sleep(60)
        
        inner_left_panel = self.TopPanel.click_slider_icon()
        manage_group_page = inner_left_panel.manage_group()
        manage_group_page.group_sidebar_close_icon.click()
        manage_group_page.move_unprovisioned_device('Switch_1','New Group','group1')
        manage_group_page.move_unprovisioned_device('Switch_2','New Group','group2')        
        
        inner_left_panel.manage_group()
        manage_group_page.move_device_to_group('group1','Switch_2')


        inner_left_panel.manage_group()
        manage_group_page.move_device_to_group('default','Switch_1')
        inner_left_panel.manage_group()
        manage_group_page.move_device_to_group('default','Switch_2')


        manage_group = inner_left_panel.manage_group()
        manage_group.delete_group('group1')
        manage_group = inner_left_panel.manage_group()
        manage_group.delete_group('group2')
 def test_ath_6520_verify_unprovisioned_switches_are_seen_in_selection_while_creating_new_group(
         self):
     firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
     device_management_page = self.LeftPanel.go_to_device_management()
     device_management_page.unassign_switch_license("Switch_1")
     monitoring_switch_page = self.LeftPanel.go_to_monitoring_switches_page(
     )
     monitoring_switch_page.delete_switch_device_based_on_ip("Switch_1")
     DeviceLibrary.factoryReset("Switch_1")
     firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
     device_management_page = self.LeftPanel.go_to_device_management()
     device_management_page.add_switch_and_assign_license("Switch_1")
     DeviceLibrary.connect_device_to_server("Switch_1")
     inner_left_panel = self.TopPanel.click_slider_icon()
     inner_left_panel.assert_device_in_group('Switch_1', 'Unprovisioned')
Esempio n. 11
0
 def test_ath_10984_attach_iap_with_deny_inter_user_bridging_and_deny_local_routing_options(self):
     conf = self.config.config_vars
     DeviceLibrary.disconnect_device_from_server('IAP_2')
     DeviceLibrary.factoryReset('IAP_2')
     time.sleep(350)
     DeviceLibrary.configure_deny_inter_user_bridging_and_deny_local_routing('IAP_2')
     DeviceLibrary.connect_device_to_server('IAP_2')
     time.sleep(400)
     self.browser.refresh()
     inner_left_panel = self.TopPanel.click_slider_icon()
     inner_left_panel.select_unprovision_iap()
     manage_group_page = inner_left_panel.click_configuration_page_existing_group_button()
     manage_group_page.move_unprovisioned_device('IAP_2',group_name='group1')
     time.sleep(20)
     DeviceLibrary.reconnect('IAP_2')
     time.sleep(400)
     self.assert_running_config_include_deny('IAP_2','deny-inter-user-bridging')
     time.sleep(20)
     self.assert_running_config_include_deny('IAP_2','deny-local-routing')
     time.sleep(20)
     DeviceLibrary.disconnect_device_from_server('IAP_2')
     DeviceLibrary.factoryReset('IAP_2')
     time.sleep(350)
     DeviceLibrary.configure_deny_inter_user_bridging_and_deny_local_routing('IAP_2')
     DeviceLibrary.connect_device_to_server('IAP_2')
     time.sleep(400)
     self.browser.refresh()
     inner_left_panel = self.TopPanel.click_slider_icon()
     inner_left_panel.select_unprovision_iap()
     create_group_page = inner_left_panel.click_configuration_page_new_group_button()
     create_group_page.move_unprovisional_device_to_new_group('group2')
     time.sleep(20)
     DeviceLibrary.reconnect('IAP_2')
     time.sleep(400)
     self.assert_running_config_include_deny('IAP_2','deny-inter-user-bridging',exists=True)
     time.sleep(20)
     self.assert_running_config_include_deny('IAP_2','deny-local-routing',exists=True)
     
     self.browser.refresh()
     inner_left_panel = self.TopPanel.click_slider_icon()
     manage_group_page = inner_left_panel.manage_group()
     manage_group_page.move_vc_to_group('group2','IAP_1')
     time.sleep(20)
     # DeviceLibrary.connect_device_to_server('IAP_2')
     # time.sleep(700)
     # self.assert_running_config_include_deny('IAP_2','deny-inter-user-bridging',exists=True)
     # self.assert_running_config_include_deny('IAP_2','deny-local-routing',exists=True)
Esempio n. 12
0
    def test_ath_11046_check_non_default_values_vc_name(self):
        myDevice = Device.getDeviceObject("IAP_1")
        vlan_id = myDevice.get("vlan")
        conf = self.config.config_vars
        system_page = self.LeftPanel.go_to_system_page()
        system_page.set_new_vc_name("IAP_1", conf.vc_name)
        system_page.set_new_vc_ip("IAP_1", conf.ip_add)
        system_page.check_non_default_values_vc_name_2()
        system_page._save_settings()
        system_page.assert_system_page_vc_field_values("IAP_1",
                                                       "sh ru | inc name",
                                                       conf.vc_name)
        system_page.assert_system_page_vc_field_values("IAP_1",
                                                       "sh ru | inc virtual",
                                                       conf.ip_add)
        system_page.assert_system_page_vc_field_values("IAP_1",
                                                       "sh ru | inc time",
                                                       "Pacific-Time -07")
        system_page.assert_system_page_vc_field_values("IAP_1",
                                                       "sh ru | inc ntp",
                                                       conf.ntp_server)
        system_page.assert_system_page_vc_field_values("IAP_1",
                                                       "sh ru | inc band",
                                                       "2.4ghz")
        system_page.assert_system_page_vc_field_values("IAP_1",
                                                       "sh ru | inc vlan",
                                                       vlan_id)
        system_page.assert_system_page_vc_field_values(
            "IAP_1", "sh ru | inc cpu", "dynamic-cpu-mgmt disable")

        time.sleep(10)
        DeviceLibrary.factoryReset("IAP_1")
        time.sleep(10)
        DeviceLibrary.getPrompt("IAP_1")
        DeviceLibrary.reconnect("IAP_1")
        time.sleep(90)
        inner_left_panel = self.TopPanel.click_slider_icon()
        inner_left_panel.click_expand_default_group_icon()
        inner_left_panel.select_vc("IAP_1")
        inner_left_panel.select_country_code(
            self.config.config_vars.country_india)
        # system_page.setting_original_vc_name("IAP_1",conf.vc_name)
        # system_page.setting_original_vc_ip("IAP_1",conf.ip_add)
        system_page.setting_default_values_2()
        system_page._save_settings()
	def test_ath_11136_wids_config_unprovisioned_iap(self):
		conf=self.config.config_vars
		import os
		os.environ['device'] = "IAP_1"
		self.take_s1_snapshot('show_ids_detection_config')
		self.TopPanel.go_to_allgroups()
		device_mgmt = self.LeftPanel.go_to_device_management()
		device_mgmt.get_and_search_mac_address()
		device_mgmt.select_virtual_controller(device_mgmt.device_selector_1)
		device_mgmt.select_assign_group()
		device_mgmt.all_group.click()
		device_mgmt.click_assign()
		logger.debug('DeviceManagement: Clicking on ok button')
		device_mgmt.ok_button.click()
		device_mgmt.assert_group_name(conf.unprovisioned)
		DeviceLibrary.factoryReset('IAP_1')
		DeviceLibrary.configureWirelessNetwork('IAP_1')
		time.sleep(90)
		# raw_input('wait')
		DeviceLibrary.getPrompt('IAP_1')
		DeviceLibrary.connect_device_to_server('IAP_1')
		time.sleep(300)
		inner_left_panel = self.TopPanel.click_slider_icon()
		time.sleep(20)
		if not inner_left_panel.verify_unprovision_iap:
			time.sleep(30)
			self.browser.refresh()
			time.sleep(10)
			self.TopPanel.click_slider_icon()
		inner_left_panel.select_unprovision_iap()
		inner_left_panel.assert_unprovisioned_alert_popup()
		inner_left_panel.select_wireless_configuration_module()
		time.sleep(20)
		# if inner_left_panel.assert_group1_and_group2():
			# if inner_left_panel.assert_sample_group_with_vc_present():
				# manage_group_page = inner_left_panel.manage_group()
				# manage_group_page.move_virtual_controller_from_Mygroup(group1=True)
				# inner_left_panel.manage_group()
				# manage_group_page.delete_specific_group(group1=True)
		
		# create_group_page = inner_left_panel.add_group()
		# create_group_page.set_group_name(conf.group_1)
		# create_group_page.select_virtual_controller(create_group_page.select_vc)
		# create_group_page.move_next()
		# create_group_page._set_group_default_device_password1()
		# inner_left_panel.select_group(inner_left_panel.group_1)
		# inner_left_panel.expand_group1.click()
		# inner_left_panel.select_vc_inside_group.click()
		
		wids_page = self.LeftPanel.go_to_wids_page()
		time.sleep(20)
		wids_page.set_detection_infra_threat_detection_level_custom('Medium')
		if inner_left_panel.close_hide_popup:
			inner_left_panel.assert_unprovisioned_alert_popup()
		wids_page.set_detection_clients_threat_detection_level_custom('High')
		if inner_left_panel.close_hide_popup:
			inner_left_panel.assert_unprovisioned_alert_popup()
		# wids_page.save_settings()
		# if inner_left_panel.close_hide_popup:
			# inner_left_panel.assert_unprovisioned_alert_popup()
		
		monitoring_page = self.LeftPanel.go_to_monitoring_page()
		time.sleep(10)
		# raw_input('wait1')
		monitoring_wids_page = self.LeftPanel.go_to_monitoring_wids()
		time.sleep(10)
		# raw_input('wait2')
		self.browser.assert_element(monitoring_page.infrastructure_detection_level_medium, "Infrastructure detection level is not set to medium ")
		time.sleep(10)
		self.browser.assert_element(monitoring_page.client_detection_level_high, "Client detection level is not set to high ")
		import os
		os.environ['device'] = "IAP_1"
		self.take_s2_snapshot('show_ids_detection_config')
		inner_left_panel.select_wireless_configuration_module()
		time.sleep(10)
		wids_page = self.LeftPanel.go_to_wids_page()
		time.sleep(20)
		wids_page.set_detection_infra_threat_detection_level_custom_changes('Off')
		if inner_left_panel.close_hide_popup:
			inner_left_panel.assert_unprovisioned_alert_popup()
		wids_page.set_detection_clients_threat_detection_level_custom_changes('Off')
		if inner_left_panel.close_hide_popup:
			inner_left_panel.assert_unprovisioned_alert_popup()
		
		# inner_left_panel = self.TopPanel.click_slider_icon()
		# if inner_left_panel.assert_group1_and_group2():
			# if inner_left_panel.assert_sample_group_with_vc_present():
				# manage_group_page = inner_left_panel.manage_group()
				# manage_group_page.move_virtual_controller_from_Mygroup(group1=True)
				# inner_left_panel.select_group(inner_left_panel.default_group_click)
				# inner_left_panel = self.TopPanel.click_slider_icon()
				# inner_left_panel.manage_group()
				# manage_group_page.delete_specific_group(group1=True)
		import os
		os.environ['device'] = "IAP_1"
		self.take_s3_snapshot('show_ids_detection_config')
		self.assert_s1_s2_diff(0)
		import os
		os.environ['device'] = "IAP_1"
		self.assert_s1_s3_diff()
		# self.clear()
		
    def test_ath_6441_move_multiple_switches_from_one_group_to_another_group_having_a_switch(
            self):
        '''
        This tescase was done with two device not 4 , if 3 device is used please uncommnet the scripts for 3rd device'''
        firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
        device_management_page = self.LeftPanel.go_to_device_management()
        device_management_page.unassign_switch_license("Switch_1")
        monitoring_switch_page = self.LeftPanel.go_to_monitoring_switches_page(
        )
        monitoring_switch_page.delete_switch_device_based_on_ip("Switch_1")
        DeviceLibrary.factoryReset("Switch_1")
        firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
        device_management_page = self.LeftPanel.go_to_device_management()
        device_management_page.add_switch_and_assign_license("Switch_1")
        DeviceLibrary.connect_device_to_server("Switch_1")

        device_management_page.unassign_switch_license("Switch_2")
        monitoring_switch_page = self.LeftPanel.go_to_monitoring_switches_page(
        )
        monitoring_switch_page.delete_switch_device_based_on_ip("Switch_2")
        DeviceLibrary.factoryReset("Switch_2")
        import time
        firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
        device_management_page = self.LeftPanel.go_to_device_management()
        time.sleep(50)
        device_management_page.add_switch_and_assign_license("Switch_2")
        time.sleep(20)
        DeviceLibrary.connect_device_to_server("Switch_2")

        # device_management_page.unassign_switch_license("Switch_3")
        # monitoring_switch_page = self.LeftPanel.go_to_monitoring_switches_page()
        # monitoring_switch_page.delete_switch_device_based_on_ip("Switch_3")
        # DeviceLibrary.factoryReset("Switch_3")
        # time.sleep(20)
        # firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
        # device_management_page = self.LeftPanel.go_to_device_management()
        # device_management_page.add_switch_and_assign_license("Switch_3")
        # time.sleep(20)
        # DeviceLibrary.connect_device_to_server("Switch_3")

        import time
        time.sleep(120)
        self.browser.refresh()

        inner_left_panel = self.TopPanel.click_slider_icon()
        manage_group_page = inner_left_panel.manage_group()
        manage_group_page.group_sidebar_close_icon.click()
        manage_group_page.move_unprovisioned_device('Switch_1', 'New Group',
                                                    'group1')
        manage_group_page.move_unprovisioned_device('Switch_2', 'New Group',
                                                    'group2')
        # manage_group_page.move_unprovisioned_device('Switch_3','Existing Group','group2')

        inner_left_panel.manage_group()
        manage_group_page.move_device_to_group('group1', 'Switch_2')
        # inner_left_panel.manage_group()
        # manage_group_page.move_device_to_group('group1','Switch_3')

        inner_left_panel.manage_group()
        manage_group_page.move_device_to_group('default', 'Switch_1')
        inner_left_panel.manage_group()
        manage_group_page.move_device_to_group('default', 'Switch_2')
        # inner_left_panel.manage_group()
        # manage_group_page.move_device_to_group('default','Switch_3')

        manage_group = inner_left_panel.manage_group()
        manage_group.delete_group('group1')
        manage_group = inner_left_panel.manage_group()
        manage_group.delete_group('group2')
    def test_ath_6441_move_multiple_switches_from_one_group_to_another_group_having_a_switch(self):
        '''
        This tescase was done with two device not 4 , if 3 device is used please uncommnet the scripts for 3rd device'''
        firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
        device_management_page = self.LeftPanel.go_to_device_management()
        device_management_page.unassign_switch_license("Switch_1")
        monitoring_switch_page = self.LeftPanel.go_to_monitoring_switches_page()
        monitoring_switch_page.delete_switch_device_based_on_ip("Switch_1")
        DeviceLibrary.factoryReset("Switch_1")
        firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
        device_management_page = self.LeftPanel.go_to_device_management()
        device_management_page.add_switch_and_assign_license("Switch_1")
        DeviceLibrary.connect_device_to_server("Switch_1")

        device_management_page.unassign_switch_license("Switch_2")
        monitoring_switch_page = self.LeftPanel.go_to_monitoring_switches_page()
        monitoring_switch_page.delete_switch_device_based_on_ip("Switch_2")
        DeviceLibrary.factoryReset("Switch_2")
        import time
        firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
        device_management_page = self.LeftPanel.go_to_device_management()
        time.sleep(50)
        device_management_page.add_switch_and_assign_license("Switch_2")
        time.sleep(20)
        DeviceLibrary.connect_device_to_server("Switch_2")
        
        # device_management_page.unassign_switch_license("Switch_3")
        # monitoring_switch_page = self.LeftPanel.go_to_monitoring_switches_page()
        # monitoring_switch_page.delete_switch_device_based_on_ip("Switch_3")
        # DeviceLibrary.factoryReset("Switch_3")
        # time.sleep(20)
        # firmware_page = self.LeftPanel.go_to_maintenance_Firmware_page()
        # device_management_page = self.LeftPanel.go_to_device_management()
        # device_management_page.add_switch_and_assign_license("Switch_3")
        # time.sleep(20)
        # DeviceLibrary.connect_device_to_server("Switch_3")
        
        import time
        time.sleep(120)
        self.browser.refresh()
        
        inner_left_panel = self.TopPanel.click_slider_icon()
        manage_group_page = inner_left_panel.manage_group()
        manage_group_page.group_sidebar_close_icon.click()
        manage_group_page.move_unprovisioned_device('Switch_1','New Group','group1')
        manage_group_page.move_unprovisioned_device('Switch_2','New Group','group2')        
        # manage_group_page.move_unprovisioned_device('Switch_3','Existing Group','group2') 
        
        inner_left_panel.manage_group()
        manage_group_page.move_device_to_group('group1','Switch_2')
        # inner_left_panel.manage_group()
        # manage_group_page.move_device_to_group('group1','Switch_3')
        
        inner_left_panel.manage_group()
        manage_group_page.move_device_to_group('default','Switch_1')
        inner_left_panel.manage_group()
        manage_group_page.move_device_to_group('default','Switch_2')
        # inner_left_panel.manage_group()
        # manage_group_page.move_device_to_group('default','Switch_3')


        manage_group = inner_left_panel.manage_group()
        manage_group.delete_group('group1')
        manage_group = inner_left_panel.manage_group()
        manage_group.delete_group('group2')
    def test_ath_11240_configure_unprovisoined_access_point(self):
        # wirte erase all and factory_reset the IAP. Configure the IAP with wireless network profile and Join the IAP to Athena-central(Configure the IAP with wireless network profile.... has to be done manually)
        conf = self.config.config_vars
        import os
        os.environ['device'] = "IAP_1"
        self.take_s1_snapshot('AP_ENV')
        self.TopPanel.go_to_allgroups()
        device_mgmt = self.LeftPanel.go_to_device_management()
        device_mgmt.get_and_search_mac_address()
        device_mgmt.select_virtual_controller(device_mgmt.device_selector_1)
        device_mgmt.select_assign_group()
        device_mgmt.all_group.click()
        device_mgmt.click_assign()
        logger.debug('DeviceManagement: Clicking on ok button')
        device_mgmt.ok_button.click()
        device_mgmt.assert_group_name(conf.unprovisioned)
        DeviceLibrary.factoryReset('IAP_1')
        DeviceLibrary.configureWirelessNetwork('IAP_1')
        time.sleep(30)
        # raw_input('wait')
        DeviceLibrary.getPrompt('IAP_1')
        DeviceLibrary.connect_device_to_server('IAP_1')
        time.sleep(300)
        inner_left_panel = self.TopPanel.click_slider_icon()
        # time.sleep(20)
        if not inner_left_panel.verify_unprovision_iap:
            time.sleep(30)
            self.browser.refresh()
            time.sleep(10)
            self.TopPanel.click_slider_icon()
        inner_left_panel.select_unprovision_iap()
        inner_left_panel.assert_unprovisioned_alert_popup()
        inner_left_panel.select_wireless_configuration_module()
        time.sleep(50)
        access_point = self.LeftPanel.go_to_access_points()
        time.sleep(50)
        access_point.edit_access_point()
        access_point.get_ip_from_dhcp.click()
        access_point.click_save_settings()
        if inner_left_panel.close_hide_popup:
            inner_left_panel.assert_unprovisioned_alert_popup()
        time.sleep(10)

        default_name = access_point.get_ap_default_name()
        access_point.assert_name_error()
        access_point.set_access_point_name(
            self.config.config_vars.new_access_point_name)
        if inner_left_panel.close_hide_popup:
            inner_left_panel.assert_unprovisioned_alert_popup()
        time.sleep(10)

        access_point.assert_new_access_name()
        access_point.select_static_radio_button()
        access_point.get_and_set_current_server_ip_netmask_dns_ip_gateway()
        access_point.click_save_settings()
        # raw_input('waiting222....')
        if inner_left_panel.close_hide_popup:
            inner_left_panel.assert_unprovisioned_alert_popup()
        time.sleep(10)

        access_point.click_edit_iap()
        access_point.click_radio_accordion()

        access_point.aa_radio_24g.click()
        time.sleep(10)
        access_point.aa_radio_5g.click()
        access_point.transmit_power.set(
            self.config.config_vars.channel_24g_value)
        access_point.transmit_power_5g.set(
            self.config.config_vars.channel_24g_value)
        access_point.click_save_settings()
        # raw_input('waiting....')
        if inner_left_panel.close_hide_popup:
            inner_left_panel.assert_unprovisioned_alert_popup()
        time.sleep(10)

        import os
        os.environ['device'] = "IAP_1"
        self.take_s2_snapshot('AP_ENV')
        self.LeftPanel.go_to_network_page()
        access_point = self.LeftPanel.go_to_access_points()
        access_point.edit_access_point()
        access_point.get_set_current_mac_address()
        access_point.get_ip_from_dhcp.click()
        access_point.click_save_settings()
        # raw_input('waiting....')
        if inner_left_panel.close_hide_popup:
            inner_left_panel.assert_unprovisioned_alert_popup()
        time.sleep(10)

        access_point.set_radio_defaults()
        if inner_left_panel.close_hide_popup:
            inner_left_panel.assert_unprovisioned_alert_popup()
        time.sleep(30)
        import os
        os.environ['device'] = "IAP_1"
        self.take_s3_snapshot('AP_ENV')
        self.assert_s1_s2_diff(0)
        import os
        os.environ['device'] = "IAP_1"
        self.assert_s1_s3_diff()
	def test_ath_11240_configure_unprovisoined_access_point(self):
		# wirte erase all and factory_reset the IAP. Configure the IAP with wireless network profile and Join the IAP to Athena-central(Configure the IAP with wireless network profile.... has to be done manually)
		conf=self.config.config_vars
		import os
		os.environ['device'] = "IAP_1"
		self.take_s1_snapshot('AP_ENV')
		self.TopPanel.go_to_allgroups()
		device_mgmt = self.LeftPanel.go_to_device_management()
		device_mgmt.get_and_search_mac_address()
		device_mgmt.select_virtual_controller(device_mgmt.device_selector_1)
		device_mgmt.select_assign_group()
		device_mgmt.all_group.click()
		device_mgmt.click_assign()
		logger.debug('DeviceManagement: Clicking on ok button')
		device_mgmt.ok_button.click()
		device_mgmt.assert_group_name(conf.unprovisioned)
		DeviceLibrary.factoryReset('IAP_1')
		DeviceLibrary.configureWirelessNetwork('IAP_1')
		time.sleep(30)
		# raw_input('wait')
		DeviceLibrary.getPrompt('IAP_1')
		DeviceLibrary.connect_device_to_server('IAP_1')
		time.sleep(300)
		inner_left_panel = self.TopPanel.click_slider_icon()
		# time.sleep(20)
		if not inner_left_panel.verify_unprovision_iap:
			time.sleep(30)
			self.browser.refresh()
			time.sleep(10)
			self.TopPanel.click_slider_icon()
		inner_left_panel.select_unprovision_iap()
		inner_left_panel.assert_unprovisioned_alert_popup()
		inner_left_panel.select_wireless_configuration_module()
		time.sleep(50)
		access_point = self.LeftPanel.go_to_access_points()
		time.sleep(50)
		access_point.edit_access_point()
		access_point.get_ip_from_dhcp.click()
		access_point.click_save_settings()
		if inner_left_panel.close_hide_popup:
			inner_left_panel.assert_unprovisioned_alert_popup()
		time.sleep(10)
		
		default_name = access_point.get_ap_default_name()
		access_point.assert_name_error()
		access_point.set_access_point_name(self.config.config_vars.new_access_point_name)
		if inner_left_panel.close_hide_popup:
			inner_left_panel.assert_unprovisioned_alert_popup()
		time.sleep(10)
		
		access_point.assert_new_access_name()
		access_point.select_static_radio_button()
		access_point.get_and_set_current_server_ip_netmask_dns_ip_gateway()
		access_point.click_save_settings()
		# raw_input('waiting222....')
		if inner_left_panel.close_hide_popup:
			inner_left_panel.assert_unprovisioned_alert_popup()
		time.sleep(10)
		
		access_point.click_edit_iap()
		access_point.click_radio_accordion()
		
		access_point.aa_radio_24g.click()
		time.sleep(10)
		access_point.aa_radio_5g.click()
		access_point.transmit_power.set(self.config.config_vars.channel_24g_value)
		access_point.transmit_power_5g.set(self.config.config_vars.channel_24g_value)
		access_point.click_save_settings()
		# raw_input('waiting....')
		if inner_left_panel.close_hide_popup:
			inner_left_panel.assert_unprovisioned_alert_popup()
		time.sleep(10)
		
		import os
		os.environ['device'] = "IAP_1"
		self.take_s2_snapshot('AP_ENV')
		self.LeftPanel.go_to_network_page()
		access_point = self.LeftPanel.go_to_access_points()
		access_point.edit_access_point()
		access_point.get_set_current_mac_address()
		access_point.get_ip_from_dhcp.click()
		access_point.click_save_settings()
		# raw_input('waiting....')
		if inner_left_panel.close_hide_popup:
			inner_left_panel.assert_unprovisioned_alert_popup()
		time.sleep(10)
		
		access_point.set_radio_defaults()
		if inner_left_panel.close_hide_popup:
			inner_left_panel.assert_unprovisioned_alert_popup()
		time.sleep(30)
		import os
		os.environ['device'] = "IAP_1"
		self.take_s3_snapshot('AP_ENV')
		self.assert_s1_s2_diff(0)
		import os
		os.environ['device'] = "IAP_1"
		self.assert_s1_s3_diff()