コード例 #1
0
    def select_restore_by_date(self, path="C:/test_data", dest="C:/RESTORE"):
        import time
        time.sleep(2)
        testfolder = path.split("/")
        file_treeview = self.SysTreeView
        date_setting = self.SearchByDate
        try:
            # file_treeview.GetItem([file_treeview.GetItem([0]).Text()]).Click(double=True)
            WindowsGUIUtil.click_button(date_setting)
            items = [file_treeview.GetItem([0]).Text()] + [
                unicode("Drive(" + testfolder[0].upper() + ")")
            ]  # + testfolder[1:]

            # Select files to restore
            file_treeview.GetItem(items).Click(double=True, where='check')

            # Set destination
            self.set_destination(dest)
            time.sleep(1)

            self.select_overwrite()
            time.sleep(1)

            # self.select_rename()

            return True
        except Exception as exc:
            raise self.retry(exc=exc, countdown=60)
            return False
コード例 #2
0
 def apply(self):
     # self.OKButton.Click()
     # okbutton = self.OKButton
     # okbutton.set_focus()
     # okbutton.DoubleClick()
     okbutton = self.OKButton
     if WindowsGUIUtil.is_visible(okbutton):
         WindowsGUIUtil.click_button(okbutton)
コード例 #3
0
 def show_restore_option(self):
     if WindowsGUIUtil.is_selected(self.CheckBox6):
         WindowsGUIUtil.click_button(self.ShowVirtualDrive)
         WindowsGUIUtil.click_button(self.ShowVirtualDrive)
         WindowsGUIUtil.click_button(self.ShowRestoreOption)
     else:
         WindowsGUIUtil.click_button(self.ShowVirtualDrive)
         WindowsGUIUtil.click_button(self.ShowRestoreOption)
コード例 #4
0
 def open_logindialog(self):
     # if self.continuesetupbutton.exists:
     continuebutton = self.ContinueSetup
     if continuebutton.exists():
         WindowsGUIUtil.click_button(continuebutton)
         time.sleep(3)
         return True
     else:
         return False
コード例 #5
0
 def set_suspend_backup(self, number, type):
     if not WindowsGUIUtil.is_selected(self.CheckBox2):
         WindowsGUIUtil.click_button(self.SuspendBackup)
     if WindowsGUIUtil.is_enabled(self.BackupType):
         if type == "hours":
             WindowsGUIUtil.select_combobox(self.BackupType, 0)
         elif type == "days":
             WindowsGUIUtil.select_combobox(self.BackupType, 1)
         elif type == "weeks":
             WindowsGUIUtil.select_combobox(self.BackupType, 2)
     WindowsGUIUtil.input_text(self.SuspendBackupFor, str(number))
コード例 #6
0
 def set_throttle_parameter(self, start_time, end_time):
     if not WindowsGUIUtil.is_selected(self.AutoRadioButton2):
         WindowsGUIUtil.click_button(self.ThrottleBetween)
     time_list1 = start_time.split(":")
     hour1 = time_list1[0]
     minute1 = time_list1[1]
     WindowsGUIUtil.set_time(self.StartTime, int(hour1), int(minute1))
     time_list2 = end_time.split(":")
     hour2 = time_list2[0]
     minute2 = time_list2[1]
     WindowsGUIUtil.set_time(self.EndTime, int(hour2), int(minute2))
コード例 #7
0
 def choose_license_agreement(self):
     WindowsGUIUtil.click_button(self.Viewthelicenseagreement)
コード例 #8
0
 def click_no(self):
     WindowsGUIUtil.click_button(self.NoButton)
コード例 #9
0
 def click_yes(self):
     WindowsGUIUtil.click_button(self.YesButton)
コード例 #10
0
 def install(self):
     time.sleep(2)
     if WindowsGUIUtil.is_visible(self.InstallButton):
         WindowsGUIUtil.click_button(self.InstallButton)
コード例 #11
0
 def apply(self):
     if WindowsGUIUtil.is_visible(self.SettingsDialog):
         WindowsGUIUtil.click_button(self.FinishButton)
コード例 #12
0
 def apply(self):
     WindowsGUIUtil.click_button(self.NextButton)
コード例 #13
0
 def cancel(self):
     WindowsGUIUtil.click_button(self.CancelButton)
コード例 #14
0
 def choose_location_change(self):
     WindowsGUIUtil.click_button(self.Chooseadifferentinstalllocation)
コード例 #15
0
 def accept(self):
     WindowsGUIUtil.click_button(self.AcceptButton)
     time.sleep(2)
コード例 #16
0
 def backup(self):
     # self.backbutton.Click()
     back_button = self.BackButton
     if WindowsGUIUtil.is_visible(back_button):
         WindowsGUIUtil.click_button(back_button)
コード例 #17
0
 def apply(self):
     # self.nextbutton.Click()
     print "Apply Summary Dialog"
     next_button = self.NextButton
     if WindowsGUIUtil.is_visible(next_button):
         WindowsGUIUtil.click_button(next_button)
コード例 #18
0
        return self.summarydialog.BackButton

    @property
    def cancelbutton(self):
        return self.summarydialog.CancelButton

    def apply(self):
        # self.nextbutton.Click()
        print "Apply Summary Dialog"
        next_button = self.NextButton
        if WindowsGUIUtil.is_visible(next_button):
            WindowsGUIUtil.click_button(next_button)

    def backup(self):
        # self.backbutton.Click()
        back_button = self.BackButton
        if WindowsGUIUtil.is_visible(back_button):
            WindowsGUIUtil.click_button(back_button)

    def cancel(self):
        # self.cancelbutton.Click()
        cancel_button = self.CancelButton
        if WindowsGUIUtil.is_visible(cancel_button):
            WindowsGUIUtil.click_button(cancel_button)


if __name__ == "__main__":
    summary = SummaryDialog("mozypro")
    # summary.apply()
    WindowsGUIUtil.click_button(summary.BackButton)
コード例 #19
0
 def apply(self):
     okbutton = self.OKButton
     if WindowsGUIUtil.is_visible(okbutton):
         WindowsGUIUtil.click_button(okbutton)
コード例 #20
0
 def back(self):
     back_button = self.BackButton
     if WindowsGUIUtil.is_visible(back_button):
         WindowsGUIUtil.click_button(back_button)
コード例 #21
0
 def apply(self):
     WindowsGUIUtil.click_button(self.NextButton)
     time.sleep(2)
コード例 #22
0
 def open_restorepanel(self):
     # self.restorebutton.Click()
     WindowsGUIUtil.click_button(self.RestoreButton)
     time.sleep(15)
コード例 #23
0
 def finish_and_exit(self):
     WindowsGUIUtil.click_button(self.FinishButton)
コード例 #24
0
 def open_settingwindow(self):
     # self.settingsbutton.Click()
     WindowsGUIUtil.click_button(self.Settings)
     time.sleep(10)
コード例 #25
0
 def back(self):
     WindowsGUIUtil.click_button(self.BackButton)
コード例 #26
0
 def open_historyspanel(self):
     # self.historybutton.Click()
     WindowsGUIUtil.click_button(self.Details)
     time.sleep(10)
コード例 #27
0
 def apply(self):
     # self.nextbutton.Click()
     okbutton = self.NextButton
     if WindowsGUIUtil.is_visible(okbutton):
         WindowsGUIUtil.click_button(okbutton)
コード例 #28
0
 def startbackup(self):
     # self.backupbutton.Click()
     WindowsGUIUtil.click_button(self.StartBackup)
コード例 #29
0
 def cancel(self):
     cancelbutton = self.CancelButton
     if WindowsGUIUtil.is_visible(cancelbutton):
         WindowsGUIUtil.click_button(cancelbutton)
コード例 #30
0
 def cancelbackup(self):
     # self.backupbutton.Click()
     WindowsGUIUtil.click_button(self.CancelBackup)