def replace_selected_computer(self, id=-1): replacebutton = self.ReplaceSelectedComputer replacecombobox = self.ReplaceComputerCombobox print replacebutton.exists() print replacecombobox.exists() WindowsGUIUtil.click_radio_button(replacebutton) # select the first computer WindowsGUIUtil.select_combobox(replacecombobox, index=id)
def set_pkey(self, pkey="test1234"): usepkeybutton = self.UsePersonalKeyButton enterkeybutton = self.EnterKeyButton if WindowsGUIUtil.is_visible(usepkeybutton): WindowsGUIUtil.click_radio_button(usepkeybutton) elif WindowsGUIUtil.is_visible(enterkeybutton): WindowsGUIUtil.click_radio_button(enterkeybutton) WindowsGUIUtil.input_text(self.EnterKeyEdit, pkey) # self.usepkeybutton.CheckByClick() # self.enterkeybutton.CheckByClick() # self.enterkeyedit.type_keys(pkey) self.apply() keyconfirmdialog = KeyConfirmDialog(self.oem) keyconfirmdialog.apply()
def use_newencryption(self): usenewencryptionbutton = self.Button4 if usenewencryptionbutton: WindowsGUIUtil.click_radio_button(usenewencryptionbutton) self.apply()
def select_rename(self): # self.renameradiobutton.CheckByClick() # Ummm. Doens't work... # self.settingswindow.RadioButton11.CheckByClick() WindowsGUIUtil.click_radio_button(self.RadioButton11)
def select_overwrite(self): # self.overwriteradiobutton.CheckByClick() # Ummm. Doens't work... # self.settingswindow.OverwriteExisting.CheckByClick() WindowsGUIUtil.click_radio_button(self.OverwriteExisting)
def require_username_and_password(self, username, password, domain=''): WindowsGUIUtil.click_radio_button(self.NeedUseInfo) WindowsGUIUtil.input_text(self.EditUsername, username) WindowsGUIUtil.input_text(self.EditPassword, password) WindowsGUIUtil.input_text(self.EditDomain, domain)
def authenticate_via_domain(self): WindowsGUIUtil.click_radio_button(self.AuthViaDomain)
def not_require_authentication(self): WindowsGUIUtil.click_radio_button(self.NoProxyAuth)
def use_auto_configuration_script(self, url): WindowsGUIUtil.click_radio_button(self.UseConfigScript) WindowsGUIUtil.input_text(self.EditURL, url)
def use_auto_proxy(self): WindowsGUIUtil.click_radio_button(self.UseAutoProxy)
def use_default_proxy(self): WindowsGUIUtil.click_radio_button(self.UseDefaultProxy)
def use_proxy(self, proxy): WindowsGUIUtil.click_radio_button(self.UseTheProxy) WindowsGUIUtil.input_text(self.EditProxy, proxy)
def not_use_proxy(self): WindowsGUIUtil.click_radio_button(self.NotUseProxy)
def add_new_computer(self): addcomputerbutton = self.AddComputer # print addcomputerbutton.exists() # print addcomputerbutton.verify_visible() WindowsGUIUtil.click_radio_button(addcomputerbutton)