Beispiel #1
0
        public void RaChangeWorkerStatus()
        {
            try
            {
                WindowsActions.KillEllisProcesses();
                App = EllisHome.LaunchEllisAsRAUser();
                var datarows = ExcelReader.ImportSpreadsheet(ExcelFileNames.WorkerAdvancedSearch);
                foreach (var datarow in datarows)
                {
                    SearchWindow.SelectSearchElements(null, "Worker", SearchWindow.SearchTypeConstants.Advanced);
                    WorkerAdvancedSearchWindow.EnterWorkerNameAsSearchData("TEST");
                    var worker = WorkerAdvancedSearchWindow.SelectWorkerfromSearchResults(datarow.ItemArray[36].ToString());
                    Factory.AssertIsTrue(worker, "Requested Worker not found");
                    if (!worker)
                    {
                        continue;
                    }

                    Playback.Wait(2000);
                    WorkerAdvancedSearchWindow.SelectApplicationChkBox(datarow);
                    WorkerSummaryWindow.SelectMainTab(WorkerSummaryWindow.WorkerProfileTabConstants.Survey);
                    Playback.Wait(1000);
                    Factory.AssertIsTrue(WorkerSurveyWindow.VerifyWorkerProfileWindowDisplayed(), "Workers Survey not Displayed");
                    WorkerSurveyWindow.EnterDatainSsn(datarow);
                    WorkerSurveyWindow.EnterDataInSurveyGrid();
                    WorkerSurveyWindow.EnterNotes(datarow);
                    Playback.Wait(1000);
                    Factory.AssertIsTrue(WorkerSurveyWindow.VerifyWorkerProfileWindowDisplayed(),
                                         "Worker Profile Window Not Displayed");
                }
            }
            finally
            {
                Cleanup();
            }
        }