示例#1
0
 public void CI_WIP___Verify_ARD_date_is_correct()
 {
     Browser.Open();
     LoginPage.SignIn();
     //Step 1  Select Work In Progress tile.
     LandingPage.NavigateToWorkInProgressPage();
     SchedulePage.MoveSlider(120);
     //Step 2  "Click  OBRA assessments and uncheck PPS form on Work In Progress page:
     //        Admission assessment
     //        Quarterly review assessment
     //        Annual assessment"
     Driver.ClickOn(WorkInProgressPage.ppsFilterButtonChecked);
     //Step 3  Verify that ARD date has displayed correctly for Admission assessment
     //Step 4  Verify that ARD date has displayed correctly for Quarterly review assessment
     //Step 5  Verify that ARD date has displayed correctly for Annual assessment
     SchedulePage.VerifyOBRAassessmentType();
     //Step 6  "Uncheck OBRA and Open PPS assessments form on Work In Progress page:
     //        5 - day scheduled assessment
     //        14 - day scheduled assessment
     //        30 - day scheduled assessment
     //        60 - day scheduled assessment
     //        90 - day scheduled assessment"
     Driver.ClickOn(WorkInProgressPage.obraFilterButtonChecked);
     Driver.ClickOn(WorkInProgressPage.ppsFilterButtonUnchecked);
     SchedulePage.VerifyPPSassessmentType();
     //Step 7  "Verify that ARD date has displayed correctly for 5 - day scheduled assessment"
     //Step 8  Verify that ARD date has displayed correctly for 14 - day scheduled assessment
     //Step 9  Verify that ARD date has displayed correctly for 30 - day scheduled assessment
     //Step 10 Verify that ARD date has displayed correctly for 60 - day scheduled assessment
     //Step 11 Verify that ARD date has displayed correctly for 90 - day scheduled assessment
 }
示例#2
0
 public void C_WIP_Sort_OBRA_PPS_buttons()
 {
     Browser.Open();
     LoginPage.SignIn();
     //Step 1  Select Work In Progress tile.
     LandingPage.NavigateToWorkInProgressPage();
     //Step 2  Verify that OBRA and PPS buttons checked
     VerifyElement.IsPresent(WorkInProgressPage.obraFilterButtonChecked);
     VerifyElement.IsPresent(WorkInProgressPage.ppsFilterButtonChecked);
     //Step 3  Verify that Work In Progress page is include OBRA and PPS assessments
     SchedulePage.MoveSlider(120);
     Driver.WaitFor(2);
     WorkInProgressPage.VerifyOBRAAssessments();
     WorkInProgressPage.VerifyPPSAssessments();
     //Step 4  Click OBRA button
     Driver.ClickOn(WorkInProgressPage.obraFilterButtonChecked);
     //Step 5  Verify that Work In Progress page is include only PPS assessments
     WorkInProgressPage.VerifyPPSAssessments();
     //Step 6  Click PPS button
     Driver.ClickOn(WorkInProgressPage.ppsFilterButtonChecked);
     //Step 7  Verify that Schedule page is include OBRA and PPS assessments
     //Step 8  Click OBRA button
     Driver.ClickOn(WorkInProgressPage.obraFilterButtonUnchecked);
     //Step 9  Verify that Work In Progress page page is include only OBRA assessments
     WorkInProgressPage.VerifyOBRAAssessments();
 }
示例#3
0
        public void EnableGIENDOSchedule()
        {
            using (Browser br = new Browser(BrowserType.Chrome, BrowserSize.Desktop_1350x900))
            {
                br.Goto(Helper.FullUrl(@"/Schedule"));
                SchedulePage sp = br.SetCurrentPageHandler(new SchedulePage());

                Assert.IsTrue(sp.IsAtPageTitle(pagetitle));
                Assert.IsTrue(sp.VerifySubmissionLink());

                //disable
                sp.ChooseCategory(@"Enable/Disable Submission Schedule (per Program)");
                sp.ChooseProgram(@"GI Endoscopy");
                sp.ChooseEnable(@"Disable");
                sp.SaveChange();

                Thread.Sleep(2000);
                Assert.IsTrue(sp.VeirfyEnableProgramMessage("Submission Schedule for 'GI Endoscopy' has been Disabled successfully"), "Disable schedule failed or message is wrong");

                //enable
                sp.ChooseEnable(@"Enable");
                sp.SaveChange();

                Thread.Sleep(2000);
                Assert.IsTrue(sp.VeirfyEnableProgramMessage("Submission Schedule for 'GI Endoscopy' has been Enabled successfully"), "Enable schedule failed or message is wrong");
            }
        }
示例#4
0
 public void EP_Assessment_Create_Admission_Validate_NC_item_set_displays()
 {
     Browser.Open();
     LoginPage.SignIn();
     //Step 1  Click the Schedule Tile.
     LandingPage.NavigateToSchedulePage();
     //Step 2  Enter the name of the resident to create an admission assessment on in the Search text box.
     Driver.ClickOn(SchedulePage.refreshFilterButton);
     //Step 3  Select the resident name from the dropdown menu.
     //Step 4  On the line item for the Admission assessment click the "Create Assessment" button.
     Driver.ClickOn(SchedulePage.createMDSBtn);
     //Step 5  Select the correct coding for an NC item set.
     SchedulePage.VistALogin();
     //The NC item set coding is as follows:
     CreateNewMDSPage.AddEntryDate();
     //1.
     Driver.ClickOn(SchedulePage.a01RadioBtn);
     //99.
     Driver.ClickOn(SchedulePage.b99RadioBtn);
     //0.
     Driver.ClickOn(SchedulePage.c0RadioBtn);
     //99.
     Driver.ClickOn(SchedulePage.f01RadioBtn);
     //Step 6  Click the "Create" button.
     Driver.ClickOn(SchedulePage.createNewMDSCreateBtnEnabled);
     //Step 7  By comparing with the currently coded specs, verify that the assessment that is displayed, matches that of the CMS NC items set spec from the manual.
     //Validate Section A - Z.
 }
示例#5
0
 public void EO_Create_Entry_Tracking_Validate_NT_item_set_displays()
 {
     Browser.Open();
     LoginPage.SignIn();
     //Step 1  Click the Resident History Tile.
     LandingPage.NavigateToResidentHistoryPage();
     //Step 2  Enter the name of the resident to create the Entry Tracking assessment on in the Resident History Sear box
     SearchResidentsPage.FindResidentWithAssessment();
     //Step 3  Select the resident tile.
     //Step 4  Click the "Create MDS" button.
     Driver.ClickOn(ResidentsHistoryPage.createNewMDSBtn);
     SchedulePage.VistALogin();
     //Step 5  Select the correct coding for an NT item set.
     CreateNewMDSPage.AddEntryDate();
     //The NC item set coding is as follows:
     //99
     Driver.ClickOn(SchedulePage.a99RadioBtn);
     //99.
     Driver.ClickOn(SchedulePage.b99RadioBtn);
     //0.
     Driver.ClickOn(SchedulePage.c0RadioBtn);
     //01.
     Driver.ClickOn(SchedulePage.f01RadioBtn);
     //Step 6  Click the "Create" button.
     Driver.ClickOn(SchedulePage.createNewMDSCreateBtnEnabled);
     //Step 7  By comparing with the currently coded specs, verify that the assessment that is displayed, matches that of the CMS NT items set spec from the manual.
     //Validate Section A - Z.
     VerifyElement.IsPresent(AssessmentPage.sectionALink);
     VerifyElement.IsPresent(AssessmentPage.sectionZLink);
 }
示例#6
0
        public virtual void SetSchedule(SchedulePage schedulePage, Schedule schedule)
        {
            var commandData = schedule.ToBytes();

            commandData[0] = new TwoNybbles((byte)schedulePage, commandData[0]).Value;
            Set(SicpCommands.SchedulingSet, commandData);
        }
示例#7
0
 public EliteMovieEntryPoint()
 {
     this.eliteMovie   = new EliteMoviePage();
     this.schedule     = new SchedulePage();
     this.selectSeat   = new SelectSeatPage();
     this.confirmation = new ConfirmationPage();
 }
示例#8
0
        public void SchedulePage_load()
        {
            using (Browser br = new Browser(BrowserType.Chrome, BrowserSize.Desktop_1350x900))
            {
                br.Goto(Helper.FullUrl(@"/Schedule"));
                SchedulePage sp = br.SetCurrentPageHandler(new SchedulePage());

                sp.TakeScreenshot(Helper.Path_Screenshot, "DSP_Schedule_chrome");
                Assert.IsTrue(sp.IsAtPageTitle(pagetitle), "Page tile is wrong, or not correct page");
            }
        }
示例#9
0
        public void DI_Resident_History___Assessments_display_on_Residents_History_Grid()
        {
            Browser.Open();
            LoginPage.SignIn();
            //Step 1  Select Resident History tile
            LandingPage.NavigateToResidentHistoryPage();
            //Step 2  Click SEARCH button
            Driver.ClickOn(SearchResidentsPage.searchButton);
            //Step 3  Select resident tile from the FIRST page
            Driver.ClickOn(SearchResidentsPage.firstResidentTile);
            //Step 4  Click CREATE MDS button
            Driver.ClickOn(ResidentsHistoryPage.createNewMDSBtn);
            SchedulePage.VistALogin();
            //Step 5  Create New MDS Assessment
            Driver.ClickOn(SchedulePage.carePlanReviewDateCalendar);
            Driver.ClickOn(SchedulePage.calendarTodayBtn);
            Driver.ClickOn(SchedulePage.a1600EntryDateCalendar);
            Driver.ClickOn(SchedulePage.calendarTodayBtn);
            Driver.ClickOn(SchedulePage.a01RadioBtn);
            Driver.ClickOn(SchedulePage.b02RadioBtn);
            Driver.ClickOn(SchedulePage.f99RadioBtn);
            Driver.ClickOn(SchedulePage.createNewMDSCreateBtnEnabled);
            VerifyElement.AreEqual(SchedulePage.assessmentHeader, "Assessment Header");
            //Step 6  Click Residents History link
            Driver.WaitForElement(By.XPath("//a[@class='ng-binding ng-scope'][contains(., 'History')]"));
            string aType1 = Driver.Instance.FindElement(By.XPath("(//p[@class='form-control-static ng-binding'])[1]")).Text.ToString();

            Driver.ClickOn(By.XPath("//a[@class='ng-binding ng-scope'][contains(., 'History')]"));
            VerifyElement.AreEqual(ResidentsHistoryPage.pageHeader, "Resident's History");
            string aType2 = Driver.Instance.FindElement(By.XPath("(//span[@class='lead ng-binding ng-scope'])[last()]//preceding-sibling::span")).Text.ToString();
            string aType3 = Driver.Instance.FindElement(By.XPath("(//span[@class='lead ng-binding ng-scope'])[last()]")).Text.ToString();
            //Step 7  Verify that  Assessment Type has display correctly on Residents History Grid
            string aTypeAdded = aType2 + " " + aType3;

            try
            {
                Assert.AreEqual(aType1, aTypeAdded);
                TestReport.Log(LogStatus.Pass, "Assessment type '" + aType1 + "' is equal to '" + aTypeAdded);
            }
            catch (AssertionException e)
            {
                string screenName     = ScreenshotHelper.TakeScreenshot();
                string screenShotPath = TestReport.AddScreenCapture(screenName);
                TestReport.Log(LogStatus.Warning, screenShotPath + "<br> Assessment type is not equal: " + e.Message);
            }
        }
示例#10
0
        public void EnableAllPrograms()
        {
            using (Browser br = new Browser(BrowserType.Chrome, BrowserSize.Desktop_1024x768)) {
                br.Goto(Helper.FullUrl(@"/Schedule"));
                SchedulePage sp = br.SetCurrentPageHandler(new SchedulePage());

                sp.ChooseCategory(@"Enable/Disable Submission Schedule (per Program)");
                foreach (string program in sp.AvailablePrograms())
                {
                    sp.ChooseProgram(program);
                    Thread.Sleep(500);
                    sp.ChooseEnable(@"Enable");
                    sp.SaveChange();
                    Thread.Sleep(1000);
                }
            }
        }
示例#11
0
 public void CA_WIP_Due_in_xx_days_slider_bar()
 {
     Browser.Open();
     LoginPage.SignIn();
     //Step 1  Select Work In Progress tile
     LandingPage.NavigateToWorkInProgressPage();
     //Step 2  Verify that slider bar has 7 days by default
     VerifyElement.IsPresent(By.XPath("//span[@class='ng-binding'][text()='7 days']"));
     //Step 3  Slide slider bar to 1 day
     SchedulePage.MoveSlider(-2);
     //Step 4  Verify by ARD date that Work In Progress page does not show any assessments later than due in 1 day
     //Step 5  Slide slider bar to 0 day
     //Step 6  Slide slider bar to 370 days
     //Step 7  Verify by ARD date that Work In Progress page does not show any assessments later than due in 370 days
     //Step 8  Slide slider bar to 371 days
     //Step 9  Slide slider bar to 10 days
     //Step 10 Verify by ARD date that Work In Progress page does not show any assessments later than due in 10 days
 }
示例#12
0
 public void CJ_WIP___Verify_Complete_by_Date_Column()
 {
     Browser.Open();
     LoginPage.SignIn();
     //Step 1  Select Work In Progress tile.
     LandingPage.NavigateToWorkInProgressPage();
     SchedulePage.MoveSlider(120);
     //Step 2  "Uncheck PPS assessments form on Work In Progress page:
     //        Admission assessment
     //        Quarterly review assessment
     //        Annual assessment"
     Driver.ClickOn(WorkInProgressPage.ppsFilterButtonChecked);
     Driver.WaitFor(2);
     //Step 3  Verify that Complete by Date Column has displayed correctly on Work In Progress page for Admission assessment
     //Step 4  Verify that Complete by Date Column has displayed correctly on Work In Progress for Quarterly review assessment
     //Step 5  Verify that Complete by Date Column has displayed correctly on Work In Progress for Annual assessment
     WorkInProgressPage.VerifyOBRAassessmentType();
 }
示例#13
0
        public void Load_SubmissionPage_SubmitGIENDO()
        {
            string filename            = "GI_ENDO_5555_201712.csv";
            string program             = "GI Endoscopy";
            string submissionperiod    = "2017, December";
            string site_schedulepage   = "5555 - CCO Test Site";
            string site_submissionpage = "5555 - CCO Test Site (555 - CCO - Test Facility)";

            using (Browser br = new Browser(BrowserType.Chrome, BrowserSize.Maximize))
            {
                //overwrite schedule
                SchedulePage p = OverrideSchedule(br, program, submissionperiod, site_schedulepage) as SchedulePage;
                p.ClickSubmissionLink();
                Thread.Sleep(1000);
                //submit file
                SubmissionPage sp = SubmitFile(br, filename, program, submissionperiod, site_submissionpage);
                Thread.Sleep(3000);
                Assert.IsTrue(sp.VerifyWarningMessage($"File Warning: [{filename}]: You are seeing this warning message because there are duplicate records (more than one procedure record for the same person on the same day) on the file"));
            }
        }
示例#14
0
        //overwrite schedule
        private TestPageBase OverrideSchedule(Browser br, string program, string submissionperiod, string siteNbr)
        {
            br.Goto(Helper.FullUrl("/Schedule"));
            SchedulePage sp = br.SetCurrentPageHandler(new SchedulePage());

            sp.ChooseCategory("Override Schedule (per Site)");
            Thread.Sleep(500);
            sp.ChooseProgram(program);
            Thread.Sleep(500);
            sp.ChooseSubmissionPeriod(submissionperiod);
            Thread.Sleep(500);
            sp.ChooseSite(siteNbr);
            Thread.Sleep(500);
            sp.SetEffectiveDate(DateTime.Now.ToString("MM/dd/yyyy 00:00"));
            sp.SetDaysEffective(2);
            sp.SaveChange();
            Thread.Sleep(1000);

            sp.TakeScreenshot(Helper.Path_Screenshot, "DSP_Override_Schedule");
            return(sp);
        }
示例#15
0
        public static void VerifyPageElements()
        {
            VerifyElement.IsPresent(homeIcon);
            VerifyElement.IsPresent(caribouCLSSuiteNavbar);
            VerifyElement.AreEqual(reportsFormsNavbar, "Reports & Forms");
            VerifyElement.IsPresent(notificationBellIcon);
            VerifyElement.IsPresent(syncStatusIcon);
            VerifyElement.IsPresent(profileIcon);
            VerifyElement.AreEqual(pageHeader, "Dashboard");
            VerifyElement.IsPresent(blueTile);
            VerifyElement.IsPresent(greenTile);
            VerifyElement.IsPresent(redTile);
            VerifyElement.IsPresent(purpleTile);
            VerifyElement.AreEqual(assessmentsByMonthLabel, "Assessments by month");
            VerifyElement.AreEqual(progressthisMonthLabel, "Progress this month");
            VerifyElement.AreEqual(adtSummeryLabel, "ADT Summary");
            VerifyElement.IsPresent(adtReportButton);
            VerifyElement.IsPresent(connectToVistaButton);
            Driver.ClickOn(By.XPath("//*[@id='main-content']/div/div/div[3]/div/div/div[2]/div/button"));
            SchedulePage.VistALogin();
            VerifyElement.IsPresent(dateLabel1);
            VerifyElement.IsPresent(circleAdmittedIcon);
            VerifyElement.IsPresent(circleDischargedIcon);
            VerifyElement.IsPresent(circleTransferedIcon);
            VerifyElement.IsPresent(dateLabel2);
            VerifyElement.IsPresent(admittedIcon);
            VerifyElement.IsPresent(dischargedIcon);
            VerifyElement.IsPresent(transferedIcon);
            VerifyElement.IsPresent(dateLabel3);
            VerifyElement.IsPresent(admittedIcon);
            VerifyElement.IsPresent(disIcon);
            VerifyElement.IsPresent(transIcon);

            //Bottom
            VerifyElement.IsPresent(caribouCLSSuiteFooter);
            VerifyElement.IsPresent(versionFooter);
            VerifyElement.IsPresent(userFooter);
            VerifyElement.IsPresent(developedByFooter);
        }
示例#16
0
        public void CD_WIP___Sort_WIP_Page_by_ARD_Date()
        {
            Browser.Open();
            LoginPage.SignIn();
            //Step 1  Select Work In Progress tile.
            LandingPage.NavigateToWorkInProgressPage();
            //Step 2  Verify that FIRST PAGE of Assessments sorted in increasing order by ARD date on Work In Progress page
            SchedulePage.MoveSlider(120);
            Driver.WaitFor(2);
            string ardDay   = Driver.Instance.FindElement(By.XPath("(//li[@class='list-group-item ng-scope']//span[@class='day ng-binding'])[1]")).Text.ToString();
            string ardMonth = Driver.Instance.FindElement(By.XPath("(//li[@class='list-group-item ng-scope']//span[@class='month ng-binding'])[1]")).Text.ToString();
            string ardYear  = Driver.Instance.FindElement(By.XPath("(//li[@class='list-group-item ng-scope']//span[@class='year ng-binding'])[1]")).Text.ToString();
            // Convert ARD days to date and time
            DateTime FirstArdDate = new DateTime(Convert.ToInt32(ardYear), SchedulePage.ConvertMonthString(ardMonth), Convert.ToInt32(ardDay));
            string   lastardDay   = Driver.Instance.FindElement(By.XPath("(//li[@class='list-group-item ng-scope']//span[@class='day ng-binding'])[last()]")).Text.ToString();
            string   lastardMonth = Driver.Instance.FindElement(By.XPath("(//li[@class='list-group-item ng-scope']//span[@class='month ng-binding'])[last()]")).Text.ToString();
            string   lastardYear  = Driver.Instance.FindElement(By.XPath("(//li[@class='list-group-item ng-scope']//span[@class='year ng-binding'])[last()]")).Text.ToString();
            // Convert ARD days to date and time
            DateTime LastArdDate = new DateTime(Convert.ToInt32(lastardYear), SchedulePage.ConvertMonthString(lastardMonth), Convert.ToInt32(lastardDay));

            if (FirstArdDate <= LastArdDate)
            {
                TestReport.Log(LogStatus.Pass, "Assessments sorted in increasing order by ARD date");
            }
            else
            {
                TestReport.Log(LogStatus.Warning, "Assessments not sorted in increasing order by ARD date");
            }
            //Step 3  Click SECOND Work In Progress page
            Driver.ClickOn(SchedulePage.nextPagination);
            //Step 4  Verify that SECOND PAGE of Assessments sorted in increasing order by ARD date on Work In Progress page
            Driver.WaitFor(3);
            string ardDay2   = Driver.Instance.FindElement(By.XPath("(//li[@class='list-group-item ng-scope']//span[@class='day ng-binding'])[1]")).Text.ToString();
            string ardMonth2 = Driver.Instance.FindElement(By.XPath("(//li[@class='list-group-item ng-scope']//span[@class='month ng-binding'])[1]")).Text.ToString();
            string ardYear2  = Driver.Instance.FindElement(By.XPath("(//li[@class='list-group-item ng-scope']//span[@class='year ng-binding'])[1]")).Text.ToString();
            // Convert ARD days to date and time
            DateTime FirstArdDate2 = new DateTime(Convert.ToInt32(ardYear2), SchedulePage.ConvertMonthString(ardMonth2), Convert.ToInt32(ardDay2));
            string   lastardDay2   = Driver.Instance.FindElement(By.XPath("(//li[@class='list-group-item ng-scope']//span[@class='day ng-binding'])[last()]")).Text.ToString();
            string   lastardMonth2 = Driver.Instance.FindElement(By.XPath("(//li[@class='list-group-item ng-scope']//span[@class='month ng-binding'])[last()]")).Text.ToString();
            string   lastardYear2  = Driver.Instance.FindElement(By.XPath("(//li[@class='list-group-item ng-scope']//span[@class='year ng-binding'])[last()]")).Text.ToString();
            // Convert ARD days to date and time
            DateTime LastArdDate2 = new DateTime(Convert.ToInt32(lastardYear2), SchedulePage.ConvertMonthString(lastardMonth2), Convert.ToInt32(lastardDay2));

            if (FirstArdDate2 <= LastArdDate2)
            {
                TestReport.Log(LogStatus.Pass, "Assessments sorted in increasing order by ARD date");
            }
            else
            {
                TestReport.Log(LogStatus.Warning, "Assessments not sorted in increasing order by ARD date");
            }
            //Step 5  Click LAST Work In Progress page
            Driver.ClickOn(SchedulePage.lastPagination);
            //Step 6  Verify that LAST PAGE of Assessments sorted in increasing order by ARD date on Work In Progress
            Driver.WaitFor(2);
            string ardDay3   = Driver.Instance.FindElement(By.XPath("(//li[@class='list-group-item ng-scope']//span[@class='day ng-binding'])[1]")).Text.ToString();
            string ardMonth3 = Driver.Instance.FindElement(By.XPath("(//li[@class='list-group-item ng-scope']//span[@class='month ng-binding'])[1]")).Text.ToString();
            string ardYear3  = Driver.Instance.FindElement(By.XPath("(//li[@class='list-group-item ng-scope']//span[@class='year ng-binding'])[1]")).Text.ToString();
            // Convert ARD days to date and time
            DateTime FirstArdDate3 = new DateTime(Convert.ToInt32(ardYear3), SchedulePage.ConvertMonthString(ardMonth3), Convert.ToInt32(ardDay3));
            string   lastardDay3   = Driver.Instance.FindElement(By.XPath("(//li[@class='list-group-item ng-scope']//span[@class='day ng-binding'])[last()]")).Text.ToString();
            string   lastardMonth3 = Driver.Instance.FindElement(By.XPath("(//li[@class='list-group-item ng-scope']//span[@class='month ng-binding'])[last()]")).Text.ToString();
            string   lastardYear3  = Driver.Instance.FindElement(By.XPath("(//li[@class='list-group-item ng-scope']//span[@class='year ng-binding'])[last()]")).Text.ToString();
            // Convert ARD days to date and time
            DateTime LastArdDate3 = new DateTime(Convert.ToInt32(lastardYear3), SchedulePage.ConvertMonthString(lastardMonth3), Convert.ToInt32(lastardDay3));

            if (FirstArdDate3 <= LastArdDate3)
            {
                TestReport.Log(LogStatus.Pass, "Assessments sorted in increasing order by ARD date");
            }
            else
            {
                TestReport.Log(LogStatus.Warning, "Assessments not sorted in increasing order by ARD date");
            }
        }
示例#17
0
文件: Home.xaml.cs 项目: jhaby/GAMERS
        public Home(UserData Userinfo, string uri)
        {
            InitializeComponent();
            try
            {
                User     = Userinfo;
                this.uri = uri;
                Loaded  += Home_Loaded;
                string NameChip = "Hi, " + User.Firstname + " " + User.Surname;
                stat = new StatusModel
                {
                    UserId = User.UserId,
                    Status = "Active"
                };

                connection = new HubConnectionBuilder()
                             .WithUrl(uri + "/updates")
                             .Build();

                connection.Closed += async(error) =>
                {
                    await Task.Delay(5000);
                    await ServerConnect();

                    await signalService.SendStatus(stat);

                    CloseHomeWindow?.Invoke();
                };

                this.StateChanged += Home_StateChanged;


                signalService = new ConnService(connection);

                signalService.StatusReceived += Cos_StatusReceived;

                signalService.AlertReceived += CasesPage_AlertEvent;

                Task.Run(async() =>
                {
                    await ServerConnect();
                });

                persons       = new PersonnelInfoViewModel();
                schedule      = new SchedulePage();
                paypage       = new PaymentPage();
                loadingWindow = new LoadingWindow();

                signalService.NewUserSync += async(string id) =>
                {
                    await signalService.ConnectionSync(User.UserId);
                };

                signalService.DisconnectUser += (string obj) =>
                {
                    Task.Run(async() =>
                    {
                        await signalService.SendStatus(stat);
                        await signalService.UpdateStatus(stat.Status, stat.UserId);
                    });
                };
                LoadMap();

                HistoryPage.historyItem += (HistoryModel obj) =>
                {
                    MainHolder.Visibility = Visibility.Visible;
                    browser.Visibility    = Visibility.Collapsed;
                    Dispatcher.Invoke(() => MainHolder.NavigationService.Navigate(new CaseDetails(obj)));
                };



                this.Closing += MainWindow_Closing;

                sService = signalService;



                Respond += (string[] details) =>
                {
                    Dispatcher.Invoke(() =>
                    {
                        ResponseView.Visibility = Visibility.Visible;
                        browser.Visibility      = Visibility.Collapsed;
                        var rpage = new ResponsePage(User, signalService, details);
                        Response.NavigationService.Navigate(rpage);


                        rpage.BtnClicked += (string obj) =>
                        {
                            switch (obj)
                            {
                            case "Close":
                                ResponseView.Visibility  = Visibility.Collapsed;
                                browser.Visibility       = Visibility.Visible;
                                RestoreButton.Visibility = Visibility.Visible;
                                break;

                            case "restart":
                                CasesModel alert = new CasesModel()
                                {
                                    DateTime    = Convert.ToDateTime(details[5]),
                                    Location    = details[2],
                                    VHTCode     = details[4],
                                    Description = details[6],
                                    Village     = details[3],
                                    Status      = "ongoing",
                                    CaseId      = details[0],
                                    Category    = details[7]
                                };
                                Dispatcher.Invoke(async() => {
                                    await signalService.RestartResponse(details[0]);
                                });
                                break;

                            case "completed":
                                Dispatcher.Invoke(() => {
                                    RadWindow.Confirm("Are you sure you want to mark case as completed?", async delegate
                                    {
                                        await signalService.CompletedCase(details[0]);
                                        RadWindow.Alert("This case has been marked as completed.", MarkCaseCompleted);
                                    });
                                });
                                break;
                            }
                        };
                    });
                };
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }
        }
示例#18
0
 public void GoToTheSchedulePage()
 {
     _student = new StudentBuilder().Build();
     _schedulePage = _homePage.TopMenu.GoToStudentsPage().GoToProfilePage().GoToSchedulePage();
 }
 public void SetBindingDetailPage(DetailPage detailPage, SchedulePage schedulePage)
 {
     bindingDetailPage   = detailPage;
     bindingSchedulePage = schedulePage;
 }
示例#20
0
        public void EM_FacilitySettings()
        {
            Browser.Open();
            LoginPage.SignIn();
            //Step 1  'Log in as Facility Administrator.
            //Step 2   Select Admin tile > Facility Settings from left hand menu.
            //LandingPage.NavigateToAdminPage();
            //AdminPage.NavigateToFacilitySettings();
            ////Step 3  "Setting Select the Urban radio button."
            //if (Driver.IsElementPresent(By.XPath("//input[@value='Urban' and @aria-checked='false']")))
            //{
            //    Driver.ClickOn(By.XPath("(//div[@class='iradio_square-blue'])[1]"));
            //}
            ////Step 4  "Facility Provider Numbers
            ////Enter 99 for National Provider Identifier
            //Driver.InsertText(FacilitySettingsPage.npiTextfield, "99");
            ////Enter 02 for CMS Certification Number
            //Driver.InsertText(FacilitySettingsPage.ccnTextfield, "02");
            ////Enter 5619AA for State Provider Number"
            //Driver.InsertText(FacilitySettingsPage.spnTextfield, "5619AA");
            ////Step 5  "AITC
            ////Enter VHAFL5619AA Assigned Facility / Provider Submission ID."
            //Driver.InsertText(FacilitySettingsPage.aitcTextfield, "VHAFL5619AA");
            ////Step 6  "A0200. Type of Provider
            ////Select the 1.Nursing home(SNF / NF) radio button."
            //if (Driver.IsElementPresent(By.XPath("//input[@id='NursingHome' and @aria-checked='false']")))
            //{
            //    Driver.ClickOn(By.XPath("(//div[@class='iradio_square-blue'])[2]"));
            //}
            ////Step 7  "A0410. Submission Requirement
            ////Select the 3.Unit is Medicare and / or Medicaid certified radio button."
            //Driver.ClickOn(By.XPath("//input[@id='Certified']//parent::div"));
            ////Step 8  "Assessment Settings
            ////Quarterly Assessment
            ////Change slider bar to 80 days
            ////Annual Assessment
            ////Change slider bar to 355 days"
            ////Step 9  Click SAVE
            //Driver.ClickOn(FacilitySettingsPage.saveButton);
            ////Step 10 Verify all settings on the Facility Settings page are still displayed to what was entered in the previous steps.
            //VerifyElement.AreEqual(By.XPath("//*[@id='toast-container']/div/div[2]"), "Saved successfully");
            ////Step 11 Select Caribou CLC Suite from left upper hand corner breadcrumb.
            //Driver.ClickOn(UserMenu.caribouCLCSuiteBreadcrumb);
            //Step 12 Select Schedule tile.

            LandingPage.NavigateToSchedulePage();
            //"Verify OBRA assessments display 80 days between Admission > Quarterly > Quarterly > Annual by moving slider bar out to 370 to see all assessment due for a resident and selecting one resident from Resident Search.
            Driver.ClickOn(SchedulePage.ppsFilterButtonChecked);
            SchedulePage.MoveSlider(120);
            SchedulePage.VerifyAdmissionToQ1DaysWithManualDays("RAIMDSRESIDENT, FOURTEEN F", 80);
            //Step 13 Verify that the Annual Assessment is NOT over 355 days after the Admission day."
            //Step 14 Select a resident with an Admission assessment due > Click CREATE MDS.
            SchedulePage.CreateMDSBy("Admission");
            SchedulePage.VistALogin();
            //"A2300. Assessment Reference Date (ARD):
            //Step 15 Change date to a different day(closer or farther to Admission Date by 2 days)."
            Driver.WaitFor(2);
            string fullDate = Driver.Instance.FindElement(SchedulePage.admissionDateCalendarData).Text.ToString();
            string m        = fullDate.Substring(0, 2);
            string d        = fullDate.Substring(3, 2);
            string y        = fullDate.Substring(6, 4);
            string dUpdate  = (Convert.ToInt32(d) + 2).ToString();
            string newDate  = m + "-" + dUpdate + "-" + y;

            Driver.InsertText(SchedulePage.calendarARDTextfield, newDate);
            Driver.InsertText(SchedulePage.entryDateCalendarTextfield, fullDate);
            //Step 16 Click CREATE.
            Driver.ClickOn(SchedulePage.createNewMDSCreateBtnEnabled);
            //Step 17 Select Section A from left side menu.
            AssessmentPage.NavigateToSectionA();
            //Step 18 "Verify A0100. Facility Provider Numbers
            //A.National Provider Identifier(NPI) is same as entered in facility settings(99)
            VerifyElement.AreEqual(AssessmentPage.a0100A, "99");
            //B.CMS Certification Number(CCN) is same as entered in facility settings(02)
            VerifyElement.AreEqual(AssessmentPage.a0100B, "02");
            //C.State Provider Number is same as entered in facility settings(5619AA)"
            VerifyElement.AreEqual(AssessmentPage.a0100C, "5619AA");
            //Step 19 Verify A0200.Type of Provider radio button 1.Nursing home(SNF / NF) is selected.
            //Step 20 Verify A0410.Unit Certification or Licensure Designation radio 3.Unit is Medicare and / or Medicaid certified is selected.
            //Step 21 Click Caribou CLC Suite bread crumb.
            //Step 22 Select Schedule tile.
            //"Select SAME resident from Resident Search box Admission created in above step to populate schedule with residents assessments.
            //Slide Due in slider bar to 370 days.
            //Step 23 Using new ARD from Admission OBRA created verify next Quarterly due is 80 days and Annual is NO MORE than 355 days."
        }
示例#21
0
        public void CN_WIP___Verify_Number_of_assessments__bottom_right()
        {
            Browser.Open();
            LoginPage.SignIn();
            //Step 1  Select Work In Progress tile.
            LandingPage.NavigateToWorkInProgressPage();
            //Step 2  Verify that "Due in" slider bar have 7 days by default
            VerifyElement.IsPresent(By.XPath("//span[@class='ng-binding'][text()='7 days']"));
            //Step 3  Verify Number of assessments (bottom right)
            //Step 4  Verify that pages has 5 assessments per page if  number of assessments (bottom right) more(equal) 5 OR less than 5 assessments in the First page if  number of assessments less than 10.
            int firstPageResidents = Driver.Instance.FindElements(WorkInProgressPage.residentsList).Count;

            Driver.WaitForElement(WorkInProgressPage.residentsList);
            Assert.AreEqual(firstPageResidents, 5);
            //Step 5  Verify that number of assessments from pages equal number of assessments(bottom right)
            if (Driver.IsElementPresent(WorkInProgressPage.nextButton))
            {
                Driver.ClickOn(WorkInProgressPage.nextButton);
                Driver.WaitFor(3);
                int secondPageResidents = Driver.Instance.FindElements(WorkInProgressPage.residentsList).Count;
                if (Driver.IsElementPresent(WorkInProgressPage.nextButton))
                {
                    Driver.ClickOn(WorkInProgressPage.nextButton);
                    Driver.WaitFor(3);
                    int thirdPageResidents = Driver.Instance.FindElements(WorkInProgressPage.residentsList).Count;
                    if (Driver.IsElementPresent(WorkInProgressPage.nextButton))
                    {
                        Driver.ClickOn(WorkInProgressPage.nextButton);
                        Driver.WaitFor(3);
                        int fourthPageResidents = Driver.Instance.FindElements(WorkInProgressPage.residentsList).Count;
                        Driver.ClickOn(WorkInProgressPage.nextButton);
                        Driver.WaitFor(3);
                        string assessments = Driver.Instance.FindElement(WorkInProgressPage.totalAssessments).Text.ToString().Substring(0, 2);
                        try
                        {
                            Assert.AreEqual(firstPageResidents + secondPageResidents + thirdPageResidents + fourthPageResidents, Convert.ToInt32(assessments));
                            TestReport.Log(LogStatus.Pass, "Assessments are equal to: " + assessments);
                        }
                        catch (Exception e)
                        {
                            string screenName     = ScreenshotHelper.TakeScreenshot();
                            string screenShotPath = TestReport.AddScreenCapture(screenName);
                            TestReport.Log(LogStatus.Warning, screenShotPath + "Assessments are not equal to: " + assessments + e.Message);
                        }
                    }
                    else
                    {
                        string assessments = Driver.Instance.FindElement(WorkInProgressPage.totalAssessments).Text.ToString().Substring(0, 2);
                        try
                        {
                            Assert.AreEqual(firstPageResidents + secondPageResidents + thirdPageResidents, Convert.ToInt32(assessments));
                            TestReport.Log(LogStatus.Pass, "Assessments are equal to: " + assessments);
                        }
                        catch (Exception e)
                        {
                            string screenName     = ScreenshotHelper.TakeScreenshot();
                            string screenShotPath = TestReport.AddScreenCapture(screenName);
                            TestReport.Log(LogStatus.Warning, screenShotPath + "Assessments are not equal to: " + assessments + e.Message);
                        }
                    }
                }
                else
                {
                    string assessments = Driver.Instance.FindElement(WorkInProgressPage.totalAssessments).Text.ToString().Substring(0, 2);
                    try
                    {
                        Assert.AreEqual(firstPageResidents + secondPageResidents, Convert.ToInt32(assessments));
                        TestReport.Log(LogStatus.Pass, "Assessments are equal to: " + assessments);
                    }
                    catch (Exception e)
                    {
                        string screenName     = ScreenshotHelper.TakeScreenshot();
                        string screenShotPath = TestReport.AddScreenCapture(screenName);
                        TestReport.Log(LogStatus.Warning, screenShotPath + "Assessments are not equal to: " + assessments + e.Message);
                    }
                }
            }
            else
            {
                string assessments = Driver.Instance.FindElement(WorkInProgressPage.totalAssessments).Text.ToString().Substring(0, 2);
                Assert.AreEqual(firstPageResidents, Convert.ToInt32(assessments));
            }
            //Step 6  Slide slider bar to 1 day
            SchedulePage.MoveSlider(-2);
            Driver.ClickOn(SchedulePage.onePagination);
            Driver.WaitFor(4);
            //Step 7  Verify Number of assessments (bottom right)
            int firstPageResidents2 = Driver.Instance.FindElements(WorkInProgressPage.residentsList).Count;

            Assert.AreEqual(firstPageResidents2, 5);
            //Step 8  Verify that pages has 5 assessments per page if  number of assessments (bottom right) more(equal) 10 OR less than 10 assessments in the First page if  number of assessments less than 10.
            //Step 9  Verify that number of assessments from pages equal number of assessments(bottom right)
            if (Driver.IsElementPresent(WorkInProgressPage.nextButton))
            {
                Driver.ClickOn(WorkInProgressPage.nextButton);
                Driver.WaitFor(3);
                int secondPageResidents = Driver.Instance.FindElements(WorkInProgressPage.residentsList).Count;
                if (Driver.IsElementPresent(WorkInProgressPage.nextButton))
                {
                    Driver.ClickOn(WorkInProgressPage.nextButton);
                    Driver.WaitFor(3);
                    int thirdPageResidents = Driver.Instance.FindElements(WorkInProgressPage.residentsList).Count;
                    if (Driver.IsElementPresent(WorkInProgressPage.nextButton))
                    {
                        Driver.ClickOn(WorkInProgressPage.nextButton);
                        Driver.WaitFor(3);
                        int fourthPageResidents = Driver.Instance.FindElements(WorkInProgressPage.residentsList).Count;
                        Driver.ClickOn(WorkInProgressPage.nextButton);
                        Driver.WaitFor(3);
                        string assessments = Driver.Instance.FindElement(WorkInProgressPage.totalAssessments).Text.ToString().Substring(0, 2);
                        try
                        {
                            Assert.AreEqual(firstPageResidents2 + secondPageResidents + thirdPageResidents + fourthPageResidents, Convert.ToInt32(assessments));
                            TestReport.Log(LogStatus.Pass, "Assessments are equal to: " + assessments);
                        }
                        catch (Exception e)
                        {
                            string screenName     = ScreenshotHelper.TakeScreenshot();
                            string screenShotPath = TestReport.AddScreenCapture(screenName);
                            TestReport.Log(LogStatus.Warning, screenShotPath + "Assessments are not equal to: " + assessments + e.Message);
                        }
                    }
                    else
                    {
                        string assessments = Driver.Instance.FindElement(WorkInProgressPage.totalAssessments).Text.ToString().Substring(0, 2);
                        try
                        {
                            Assert.AreEqual(firstPageResidents2 + secondPageResidents + thirdPageResidents, Convert.ToInt32(assessments));
                            TestReport.Log(LogStatus.Pass, "Assessments are equal to: " + assessments);
                        }
                        catch (Exception e)
                        {
                            string screenName     = ScreenshotHelper.TakeScreenshot();
                            string screenShotPath = TestReport.AddScreenCapture(screenName);
                            TestReport.Log(LogStatus.Warning, screenShotPath + "Assessments are not equal to: " + assessments + e.Message);
                        }
                    }
                }
                else
                {
                    string assessments = Driver.Instance.FindElement(WorkInProgressPage.totalAssessments).Text.ToString().Substring(0, 2);
                    try
                    {
                        Assert.AreEqual(firstPageResidents2 + secondPageResidents, Convert.ToInt32(assessments));
                        TestReport.Log(LogStatus.Pass, "Assessments are equal to: " + assessments);
                    }
                    catch (Exception e)
                    {
                        string screenName     = ScreenshotHelper.TakeScreenshot();
                        string screenShotPath = TestReport.AddScreenCapture(screenName);
                        TestReport.Log(LogStatus.Warning, screenShotPath + "Assessments are not equal to: " + assessments + e.Message);
                    }
                }
            }
            else
            {
                string assessments = Driver.Instance.FindElement(WorkInProgressPage.totalAssessments).Text.ToString().Substring(0, 2);
                Assert.AreEqual(firstPageResidents2, Convert.ToInt32(assessments));
            }
            //Step 10 Slide slider bar to 370 days
            SchedulePage.MoveSlider(120);
            Driver.ClickOn(SchedulePage.onePagination);
            Driver.WaitFor(3);
            //Step 11 Verify Number of assessments (bottom right)
            int firstPageResidents3 = Driver.Instance.FindElements(WorkInProgressPage.residentsList).Count;

            Assert.AreEqual(firstPageResidents3, 5);
            //Step 12 Verify that pages has 5 assessments per page if  number of assessments (bottom right) more(equal) 10 OR less than 10 assessments in the First page if  number of assessments less than 10.
            //Step 13 Verify that number of assessments from pages equal number of assessments(bottom right)
            if (Driver.IsElementPresent(WorkInProgressPage.nextButton))
            {
                Driver.ClickOn(WorkInProgressPage.nextButton);
                Driver.WaitFor(3);
                int secondPageResidents = Driver.Instance.FindElements(WorkInProgressPage.residentsList).Count;
                if (Driver.IsElementPresent(WorkInProgressPage.nextButton))
                {
                    Driver.ClickOn(WorkInProgressPage.nextButton);
                    Driver.WaitFor(3);
                    int thirdPageResidents = Driver.Instance.FindElements(WorkInProgressPage.residentsList).Count;
                    if (Driver.IsElementPresent(WorkInProgressPage.nextButton))
                    {
                        Driver.ClickOn(WorkInProgressPage.nextButton);
                        Driver.WaitFor(3);
                        int fourthPageResidents = Driver.Instance.FindElements(WorkInProgressPage.residentsList).Count;
                        Driver.ClickOn(WorkInProgressPage.nextButton);
                        Driver.WaitFor(3);
                        string assessments = Driver.Instance.FindElement(WorkInProgressPage.totalAssessments).Text.ToString().Substring(0, 2);
                        try
                        {
                            Assert.AreEqual(firstPageResidents3 + secondPageResidents + thirdPageResidents + fourthPageResidents, Convert.ToInt32(assessments));
                            TestReport.Log(LogStatus.Pass, "Assessments are equal to: " + assessments);
                        }
                        catch (Exception e)
                        {
                            string screenName     = ScreenshotHelper.TakeScreenshot();
                            string screenShotPath = TestReport.AddScreenCapture(screenName);
                            TestReport.Log(LogStatus.Warning, screenShotPath + "Assessments are not equal to: " + assessments + e.Message);
                        }
                    }
                    else
                    {
                        string assessments = Driver.Instance.FindElement(WorkInProgressPage.totalAssessments).Text.ToString().Substring(0, 2);
                        try
                        {
                            Assert.AreEqual(firstPageResidents3 + secondPageResidents + thirdPageResidents, Convert.ToInt32(assessments));
                            TestReport.Log(LogStatus.Pass, "Assessments are equal to: " + assessments);
                        }
                        catch (Exception e)
                        {
                            string screenName     = ScreenshotHelper.TakeScreenshot();
                            string screenShotPath = TestReport.AddScreenCapture(screenName);
                            TestReport.Log(LogStatus.Warning, screenShotPath + "Assessments are not equal to: " + assessments + e.Message);
                        }
                    }
                }
                else
                {
                    string assessments = Driver.Instance.FindElement(WorkInProgressPage.totalAssessments).Text.ToString().Substring(0, 2);
                    try
                    {
                        Assert.AreEqual(firstPageResidents3 + secondPageResidents, Convert.ToInt32(assessments));
                        TestReport.Log(LogStatus.Pass, "Assessments are equal to: " + assessments);
                    }
                    catch (Exception e)
                    {
                        string screenName     = ScreenshotHelper.TakeScreenshot();
                        string screenShotPath = TestReport.AddScreenCapture(screenName);
                        TestReport.Log(LogStatus.Warning, screenShotPath + "Assessments are not equal to: " + assessments + e.Message);
                    }
                }
            }
            else
            {
                string assessments = Driver.Instance.FindElement(WorkInProgressPage.totalAssessments).Text.ToString().Substring(0, 2);
                Assert.AreEqual(firstPageResidents3, Convert.ToInt32(assessments));
            }
        }
示例#22
0
 public virtual Schedule GetSchedule(SchedulePage schedule)
 {
     return(Get <Schedule>(SicpCommands.SchedulingGet, (byte)schedule));
 }
示例#23
0
 public App()
 {
     Syncfusion.Licensing.SyncfusionLicenseProvider.RegisterLicense("MjY2MjM5QDMxMzgyZTMxMmUzMFgrS1JiNHBqd2U0cUhUdDR3dVlEUEdrMUlSeU9qZ0xqR2E5bDduL0tWS0k9");
     InitializeComponent();
     MainPage = new SchedulePage();
 }
示例#24
0
        private void MenuItem_Click_3(object sender, RoutedEventArgs e)
        {
            SchedulePage page = new SchedulePage();

            frameContent.Content = page;
        }