Overview

Namespaces

  • Azalea
    • Selenium
      • App
        • Charts
        • Components
        • Encounters
        • Home
        • Login
        • Main
        • Messages
        • Patients
        • Scheduler
      • Core
      • EHR
        • UI
          • Charts
          • Documents
          • Encounters
          • Home
          • Messaging
            • Folders
          • Patients
          • Payments
          • Precerts
          • Reports
          • Scheduler
          • Settings
            • General
              • Locations
              • Roles
              • Users
        • User
      • Login
        • UI
      • PHR
        • UI
        • User
      • Toolkit
        • Exception
        • Validation
    • Util
  • None
  • tests
    • integration
      • barebones
        • controllers
          • charts
          • patients
          • system
        • models
          • billing
          • encounters
          • examples
          • messaging
          • rcm
          • system
    • unit
      • barebones
        • lib
        • utilities
          • calculations

Classes

  • AddPatientTest
  • Azalea\Selenium\App\ApplicationTestCase
  • Azalea\Selenium\App\Charts\Chart
  • Azalea\Selenium\App\Charts\ChartAssessment
  • Azalea\Selenium\App\Charts\ChartDiagnosisCodes
  • Azalea\Selenium\App\Charts\ChartListControls
  • Azalea\Selenium\App\Charts\ChartObjective
  • Azalea\Selenium\App\Charts\ChartProcedureCodes
  • Azalea\Selenium\App\Charts\Charts
  • Azalea\Selenium\App\Charts\ChartSubjective
  • Azalea\Selenium\App\Components\CodeLookup
  • Azalea\Selenium\App\Components\CollectionGrid
  • Azalea\Selenium\App\Components\Popup
  • Azalea\Selenium\App\Customers
  • Azalea\Selenium\App\Encounters\Encounter
  • Azalea\Selenium\App\Encounters\EncounterDiagnosisCodes
  • Azalea\Selenium\App\Encounters\EncounterLedger
  • Azalea\Selenium\App\Encounters\EncounterProcedureCodes
  • Azalea\Selenium\App\Encounters\Encounters
  • Azalea\Selenium\App\Home\Home
  • Azalea\Selenium\App\Login\LoginPage
  • Azalea\Selenium\App\Main\MainSearch
  • Azalea\Selenium\App\Messages\Messages
  • Azalea\Selenium\App\Patients
  • Azalea\Selenium\App\Patients\Patient
  • Azalea\Selenium\App\Patients\PatientCharts
  • Azalea\Selenium\App\Patients\PatientEditDemographicsForm
  • Azalea\Selenium\App\Patients\PatientEncounters
  • Azalea\Selenium\App\Patients\PatientFaker
  • Azalea\Selenium\App\Patients\PatientList
  • Azalea\Selenium\App\Patients\PatientListFilters
  • Azalea\Selenium\App\Patients\Patients
  • Azalea\Selenium\App\Providers
  • Azalea\Selenium\App\Scheduler\AppointmentPopup
  • Azalea\Selenium\App\Scheduler\Scheduler
  • Azalea\Selenium\App\Users
  • Azalea\Selenium\Core\BaseTestCase
  • Azalea\Selenium\Core\Browser
  • Azalea\Selenium\Core\Page
  • Azalea\Selenium\Core\User
  • Azalea\Selenium\Core\View
  • Azalea\Selenium\Core\WebDriver
  • Azalea\Selenium\EHR\Application
  • Azalea\Selenium\EHR\EHR
  • Azalea\Selenium\EHR\EHRTestCase
  • Azalea\Selenium\EHR\EMR
  • Azalea\Selenium\EHR\PM
  • Azalea\Selenium\EHR\UI\Charts\ChartsList
  • Azalea\Selenium\EHR\UI\Charts\ChartsListRow
  • Azalea\Selenium\EHR\UI\Charts\ChartsListTab
  • Azalea\Selenium\EHR\UI\CheckboxGrid
  • Azalea\Selenium\EHR\UI\Documents\Documents
  • Azalea\Selenium\EHR\UI\Documents\DocumentsTab
  • Azalea\Selenium\EHR\UI\Encounters\Encounters
  • Azalea\Selenium\EHR\UI\Encounters\EncountersTab
  • Azalea\Selenium\EHR\UI\Grid
  • Azalea\Selenium\EHR\UI\GridRow
  • Azalea\Selenium\EHR\UI\Heading
  • Azalea\Selenium\EHR\UI\Home\Home
  • Azalea\Selenium\EHR\UI\Home\OfficeOverview
  • Azalea\Selenium\EHR\UI\LockScreen
  • Azalea\Selenium\EHR\UI\MainMenu
  • Azalea\Selenium\EHR\UI\MainSearch
  • Azalea\Selenium\EHR\UI\Messaging\Folders\MessagingAllMail
  • Azalea\Selenium\EHR\UI\Messaging\Folders\MessagingInbox
  • Azalea\Selenium\EHR\UI\Messaging\Folders\MessagingSentMail
  • Azalea\Selenium\EHR\UI\Messaging\Folders\MessagingStarred
  • Azalea\Selenium\EHR\UI\Messaging\Folders\MessagingTrashed
  • Azalea\Selenium\EHR\UI\Messaging\Messaging
  • Azalea\Selenium\EHR\UI\Messaging\MessagingCompose
  • Azalea\Selenium\EHR\UI\Messaging\MessagingFolder
  • Azalea\Selenium\EHR\UI\Messaging\MessagingMenu
  • Azalea\Selenium\EHR\UI\Messaging\MessagingReply
  • Azalea\Selenium\EHR\UI\Messaging\MessagingTab
  • Azalea\Selenium\EHR\UI\Messaging\MessagingViewMessage
  • Azalea\Selenium\EHR\UI\Module
  • Azalea\Selenium\EHR\UI\Notifications
  • Azalea\Selenium\EHR\UI\Patients\ChartsListRow
  • Azalea\Selenium\EHR\UI\Patients\ChartsTab
  • Azalea\Selenium\EHR\UI\Patients\PatientAllergies
  • Azalea\Selenium\EHR\UI\Patients\PatientAllergyEditPopup
  • Azalea\Selenium\EHR\UI\Patients\PatientAllergySearchPopup
  • Azalea\Selenium\EHR\UI\Patients\PatientAppointments
  • Azalea\Selenium\EHR\UI\Patients\PatientAssembly
  • Azalea\Selenium\EHR\UI\Patients\PatientCharts
  • Azalea\Selenium\EHR\UI\Patients\PatientChartsList
  • Azalea\Selenium\EHR\UI\Patients\PatientComments
  • Azalea\Selenium\EHR\UI\Patients\PatientDashboard
  • Azalea\Selenium\EHR\UI\Patients\PatientDemographics
  • Azalea\Selenium\EHR\UI\Patients\PatientDemographicsPopup
  • Azalea\Selenium\EHR\UI\Patients\PatientDocuments
  • Azalea\Selenium\EHR\UI\Patients\PatientDocumentsList
  • Azalea\Selenium\EHR\UI\Patients\PatientEncounters
  • Azalea\Selenium\EHR\UI\Patients\PatientEncountersAddPopup
  • Azalea\Selenium\EHR\UI\Patients\PatientHandouts
  • Azalea\Selenium\EHR\UI\Patients\PatientInsurance
  • Azalea\Selenium\EHR\UI\Patients\PatientLabOrders
  • Azalea\Selenium\EHR\UI\Patients\PatientLabOrdersAddView
  • Azalea\Selenium\EHR\UI\Patients\PatientMedications
  • Azalea\Selenium\EHR\UI\Patients\PatientPortal
  • Azalea\Selenium\EHR\UI\Patients\PatientRecalls
  • Azalea\Selenium\EHR\UI\Patients\Patients
  • Azalea\Selenium\EHR\UI\Patients\PatientSearchPopup
  • Azalea\Selenium\EHR\UI\Patients\PatientSection
  • Azalea\Selenium\EHR\UI\Patients\PatientSidebar
  • Azalea\Selenium\EHR\UI\Patients\PatientsList
  • Azalea\Selenium\EHR\UI\Patients\PatientsListRow
  • Azalea\Selenium\EHR\UI\Patients\PatientsListTab
  • Azalea\Selenium\EHR\UI\Patients\PatientsTab
  • Azalea\Selenium\EHR\UI\Patients\PatientTab
  • Azalea\Selenium\EHR\UI\Patients\PatientTasks
  • Azalea\Selenium\EHR\UI\Patients\PatientVitals
  • Azalea\Selenium\EHR\UI\Patients\PatientVitalsAddPopup
  • Azalea\Selenium\EHR\UI\Payments\EDIRemitsTab
  • Azalea\Selenium\EHR\UI\Payments\Payments
  • Azalea\Selenium\EHR\UI\Payments\PaymentsTab
  • Azalea\Selenium\EHR\UI\Payments\UnappliedPaymentsTab
  • Azalea\Selenium\EHR\UI\Popup
  • Azalea\Selenium\EHR\UI\PopupConfirm
  • Azalea\Selenium\EHR\UI\PopupError
  • Azalea\Selenium\EHR\UI\Precerts\Precerts
  • Azalea\Selenium\EHR\UI\Precerts\PrecertsTab
  • Azalea\Selenium\EHR\UI\Reports\AuditLogTab
  • Azalea\Selenium\EHR\UI\Reports\ClinicalQualityMeasuresTab
  • Azalea\Selenium\EHR\UI\Reports\ClinicalQualityMeasuresValueSetsTab
  • Azalea\Selenium\EHR\UI\Reports\MeaningfulUseTab
  • Azalea\Selenium\EHR\UI\Reports\PatientStatementsTab
  • Azalea\Selenium\EHR\UI\Reports\RecordsTab
  • Azalea\Selenium\EHR\UI\Reports\Reports
  • Azalea\Selenium\EHR\UI\Reports\ReportsQueueTab
  • Azalea\Selenium\EHR\UI\Reports\ReportsTab
  • Azalea\Selenium\EHR\UI\Reports\SystemStatisticsTab
  • Azalea\Selenium\EHR\UI\Scheduler\AppointmentsRequestsTab
  • Azalea\Selenium\EHR\UI\Scheduler\AppointmentsTab
  • Azalea\Selenium\EHR\UI\Scheduler\RecallsTab
  • Azalea\Selenium\EHR\UI\Scheduler\Scheduler
  • Azalea\Selenium\EHR\UI\Scheduler\SchedulerTab
  • Azalea\Selenium\EHR\UI\SelectDropdown
  • Azalea\Selenium\EHR\UI\Settings\BillingTab
  • Azalea\Selenium\EHR\UI\Settings\General\GroupsSection
  • Azalea\Selenium\EHR\UI\Settings\General\HandoutsSection
  • Azalea\Selenium\EHR\UI\Settings\General\InsurancesSection
  • Azalea\Selenium\EHR\UI\Settings\General\Locations\LocationRow
  • Azalea\Selenium\EHR\UI\Settings\General\Locations\LocationsList
  • Azalea\Selenium\EHR\UI\Settings\General\LocationsSection
  • Azalea\Selenium\EHR\UI\Settings\General\ProvidersSection
  • Azalea\Selenium\EHR\UI\Settings\General\Roles\RoleCreatePopup
  • Azalea\Selenium\EHR\UI\Settings\General\Roles\RoleRow
  • Azalea\Selenium\EHR\UI\Settings\General\Roles\RolesList
  • Azalea\Selenium\EHR\UI\Settings\General\RolesSection
  • Azalea\Selenium\EHR\UI\Settings\General\Users\UserDetails
  • Azalea\Selenium\EHR\UI\Settings\General\Users\UserRow
  • Azalea\Selenium\EHR\UI\Settings\General\Users\UsersList
  • Azalea\Selenium\EHR\UI\Settings\General\UsersSection
  • Azalea\Selenium\EHR\UI\Settings\GeneralTab
  • Azalea\Selenium\EHR\UI\Settings\InventoryTab
  • Azalea\Selenium\EHR\UI\Settings\MedicalTab
  • Azalea\Selenium\EHR\UI\Settings\PatientTab
  • Azalea\Selenium\EHR\UI\Settings\SchedulerTab
  • Azalea\Selenium\EHR\UI\Settings\Settings
  • Azalea\Selenium\EHR\UI\TabContainer
  • Azalea\Selenium\EHR\UI\TabPanel
  • Azalea\Selenium\EHR\UI\UserAccountMenu
  • Azalea\Selenium\EHR\User\EHRAdminTestingUser
  • Azalea\Selenium\EHR\User\EMRAdminTestingUser
  • Azalea\Selenium\EHR\User\PMAdminTestingUser
  • Azalea\Selenium\Login\LoginPage
  • Azalea\Selenium\Login\LoginTestCase
  • Azalea\Selenium\Login\ResetPasswordPage
  • Azalea\Selenium\Login\UI\LoginForm
  • Azalea\Selenium\Login\UI\ResetPasswordForm
  • Azalea\Selenium\PHR\Application
  • Azalea\Selenium\PHR\PHR
  • Azalea\Selenium\PHR\PHRTestCase
  • Azalea\Selenium\PHR\UI\PopupError
  • Azalea\Selenium\PHR\User\PHRTestingUser
  • Azalea\Selenium\Toolkit\Dom
  • Azalea\Selenium\Toolkit\NestedHashMap
  • Azalea\Selenium\Toolkit\ResourceLoader
  • Azalea\Selenium\Toolkit\SauceLabsTestCase
  • Azalea\Selenium\Toolkit\SeleniumTestCase
  • Azalea\Selenium\Toolkit\TestCase
  • Azalea\Selenium\Toolkit\Validation\ElementExists
  • Azalea\Selenium\Toolkit\Validation\ElementHasText
  • Azalea\Selenium\Toolkit\Validation\ElementVisible
  • Azalea\Selenium\Toolkit\Validation\PageTitle
  • Azalea\Selenium\Toolkit\Validation\ValidationRule
  • Azalea\Selenium\Toolkit\Validation\ViewExists
  • Azalea\Selenium\Toolkit\Validation\WebDriverValidator
  • Azalea\Selenium\Toolkit\View
  • Azalea\Util\Config
  • Azalea\Util\Debug
  • Azalea_Sniffs_WhiteSpace_ScopeClosingBraceSniff
  • BaseModelTestCase
  • ChartAssessmentTest
  • ChartCustomFieldBehaviorsTest
  • ChartDiagnosisTest
  • ChartEncounterDiagnosisTest
  • ChartEncounterProceduresTest
  • ChartInventoryTest
  • ChartObjectiveTest
  • ChartProblemHistoryTest
  • ChartProceduresTest
  • ChartProviderAccessTest
  • ChartSigningTest
  • ChartsListProviderAccessTest
  • ChartSmokingStatusTest
  • ChartSubjectiveTest
  • ConfigTest
  • EncounterClaimsTest
  • EncounterDemographicsTest
  • EncounterDiagnosisTest
  • EncounterGuarantorTest
  • EncounterLedgerTest
  • EncounterProceduresTest
  • ExampleTestCase
  • MessagesLabelsTest
  • PageTest
  • PatentsListTest
  • PathManagerTest
  • PatientAccountSummaryTest
  • PatientBillingActionsTest
  • PatientCommentsTest
  • PatientDashboardAlertsTest
  • PatientDashboardLinkedPatientsTest
  • PatientDemographicsEditTest
  • PatientDocumentsTest
  • PatientPopupCommentsTest
  • PatientProviderAccessTest
  • PatientsListProviderAccessTest
  • PermissionsTest
  • PopupTest
  • SchedulerBlocksTest
  • SchedulerInsuranceBlocksTest
  • SimpePage
  • SimpleView
  • SimpleViewWithArgs
  • SimpleViewWithNoHash
  • TestCase
  • tests\integration\barebones\BarebonesConstants
  • tests\integration\barebones\BarebonesTestCase
  • tests\integration\barebones\controllers\charts\ChartsControllerTest
  • tests\integration\barebones\controllers\patients\PatientsPopupAlertsControllerTest
  • tests\integration\barebones\controllers\system\ClientsControllerTest
  • tests\integration\barebones\models\billing\ClientsFeeSchedulesMapModelTest
  • tests\integration\barebones\models\encounters\AppointmentModelTest
  • tests\integration\barebones\models\encounters\CollectionTest
  • tests\integration\barebones\models\encounters\ConcurrentCollectionTest
  • tests\integration\barebones\models\encounters\EncounterModelTest
  • tests\integration\barebones\models\encounters\EncountersIncompleteReasonModelTest
  • tests\integration\barebones\models\encounters\ModelQueryBuilderTest
  • tests\integration\barebones\models\examples\ExampleModelBasicsTest
  • tests\integration\barebones\models\examples\ExamplesGenericControllerTest
  • tests\integration\barebones\models\messaging\MessageModelTest
  • tests\integration\barebones\models\rcm\RCMStatsGeneralControllerTests
  • tests\integration\barebones\models\system\ClientModelTest
  • tests\unit\barebones\lib\BarebonesTestCase
  • tests\unit\barebones\utilities\ArraysTest
  • tests\unit\barebones\utilities\calculations\PovertyLineTest
  • tests\unit\barebones\utilities\MathTest
  • UrlManagerTest
  • VariantRulesTest
  • VariantsManagerTest
  • ViewTest
  • WebDriverMock

Exceptions

  • Azalea\Selenium\Toolkit\Exception\ElementNotFoundException
  • Azalea\Selenium\Toolkit\Exception\InvalidPageException
  • Azalea\Selenium\Toolkit\Exception\TimeoutException
  • Overview
  • Namespace
  • Class
  1: <?php
  2: use Azalea\Selenium\App\ApplicationTestCase;
  3: use Azalea\Selenium\App\Patients;
  4: use Azalea\Selenium\App\Users;
  5: 
  6: class SchedulerInsuranceBlocksTest extends ApplicationTestCase
  7: {
  8:     /**
  9:      * Summary:
 10:      * Schedules that are defined with insurance blocks appear on the scheduler
 11:      * with a shield icon indicating an insurance block for both
 12:      * non-appointment and appointment reasons. Non-appointment reason blocks
 13:      * appear with the text "Open".
 14:      */
 15:     public function testInsuranceBlocksAppearOnScheduler()
 16:     {
 17:         $app = $this->login(Users::FELIX_MILLER, Users::PASSWORD);
 18: 
 19:         // Navigate to the Scheduler
 20:         $scheduler = $app->scheduler->navigate()->verifyAndWait();
 21: 
 22:         // Select Location North Lorenburgh Family Office (402)
 23:         $this->wait(1);
 24:         $scheduler->changeLocation(402);
 25: 
 26:         // Select date 09/01/2016
 27:         $scheduler->goToDate(new DateTime("09/01/2016"));
 28:         $this->wait(1);
 29: 
 30:         /**
 31:          * Expected:
 32:          *  a. Open slots with insurance icon from 9:00 AM to 10:00 AM.
 33:          *  b. Consultation open slots with insurance icon from 10:00 AM
 34:          *     to 11:00 AM.
 35:          */
 36:         $this->spinWait(function ($driver) use ($scheduler) {
 37:             $scheduler->scrollTo("0900");
 38:             $driver->assertElementHasText("#p3552_0900 .sched_block", "Open");
 39:             $driver->assertElementExists("#p3552_0900 .sched_block .shield16");
 40:             $driver->assertElementHasText("#p3552_0905 .sched_block", "Open");
 41:             $driver->assertElementExists("#p3552_0905 .sched_block .shield16");
 42:             $driver->assertElementHasText("#p3552_0910 .sched_block", "Open");
 43:             $driver->assertElementExists("#p3552_0910 .sched_block .shield16");
 44:             $driver->assertElementHasText("#p3552_0915 .sched_block", "Open");
 45:             $driver->assertElementExists("#p3552_0915 .sched_block .shield16");
 46:             $driver->assertElementHasText("#p3552_0920 .sched_block", "Open");
 47:             $driver->assertElementExists("#p3552_0920 .sched_block .shield16");
 48:             $driver->assertElementHasText("#p3552_0925 .sched_block", "Open");
 49:             $driver->assertElementExists("#p3552_0925 .sched_block .shield16");
 50: 
 51:             $scheduler->scrollTo("0930");
 52:             $driver->assertElementHasText("#p3552_0930 .sched_block", "Open");
 53:             $driver->assertElementExists("#p3552_0930 .sched_block .shield16");
 54:             $driver->assertElementHasText("#p3552_0935 .sched_block", "Open");
 55:             $driver->assertElementExists("#p3552_0935 .sched_block .shield16");
 56:             $driver->assertElementHasText("#p3552_0940 .sched_block", "Open");
 57:             $driver->assertElementExists("#p3552_0940 .sched_block .shield16");
 58:             $driver->assertElementHasText("#p3552_0945 .sched_block", "Open");
 59:             $driver->assertElementExists("#p3552_0945 .sched_block .shield16");
 60:             $driver->assertElementHasText("#p3552_0950 .sched_block", "Open");
 61:             $driver->assertElementExists("#p3552_0950 .sched_block .shield16");
 62:             $driver->assertElementHasText("#p3552_0955 .sched_block", "Open");
 63:             $driver->assertElementExists("#p3552_0955 .sched_block .shield16");
 64: 
 65:             $scheduler->scrollTo("1000");
 66:             $driver->assertElementHasText("#p3552_1000 .sched_block", "Consultation");
 67:             $driver->assertElementExists("#p3552_1000 .sched_block .shield16");
 68:             $driver->assertElementHasText("#p3552_1005 .sched_block", "Consultation");
 69:             $driver->assertElementExists("#p3552_1005 .sched_block .shield16");
 70:             $driver->assertElementHasText("#p3552_1010 .sched_block", "Consultation");
 71:             $driver->assertElementExists("#p3552_1010 .sched_block .shield16");
 72:             $driver->assertElementHasText("#p3552_1015 .sched_block", "Consultation");
 73:             $driver->assertElementExists("#p3552_1015 .sched_block .shield16");
 74:             $driver->assertElementHasText("#p3552_1020 .sched_block", "Consultation");
 75:             $driver->assertElementExists("#p3552_1020 .sched_block .shield16");
 76:             $driver->assertElementHasText("#p3552_1025 .sched_block", "Consultation");
 77:             $driver->assertElementExists("#p3552_1025 .sched_block .shield16");
 78: 
 79:             $scheduler->scrollTo("1030");
 80:             $driver->assertElementHasText("#p3552_1030 .sched_block", "Consultation");
 81:             $driver->assertElementExists("#p3552_1030 .sched_block .shield16");
 82:             $driver->assertElementHasText("#p3552_1035 .sched_block", "Consultation");
 83:             $driver->assertElementExists("#p3552_1035 .sched_block .shield16");
 84:             $driver->assertElementHasText("#p3552_1040 .sched_block", "Consultation");
 85:             $driver->assertElementExists("#p3552_1040 .sched_block .shield16");
 86:             $driver->assertElementHasText("#p3552_1045 .sched_block", "Consultation");
 87:             $driver->assertElementExists("#p3552_1045 .sched_block .shield16");
 88:             $driver->assertElementHasText("#p3552_1050 .sched_block", "Consultation");
 89:             $driver->assertElementExists("#p3552_1050 .sched_block .shield16");
 90:             $driver->assertElementHasText("#p3552_1055 .sched_block", "Consultation");
 91:             $driver->assertElementExists("#p3552_1055 .sched_block .shield16");
 92: 
 93:             return true;
 94:         });
 95: 
 96:         $this->assertNoErrorPopups();
 97:     }
 98: 
 99:     /**
100:      * Summary:
101:      * Tests that a self-pay patient cannot be scheduled on a slot with
102:      * insurance block restrictions.
103:      */
104:     public function testCannotScheduleSelfPayOnInsuranceBlock()
105:     {
106:         $app = $this->login(Users::FELIX_MILLER, Users::PASSWORD);
107: 
108:         // Navigate to the Scheduler
109:         $scheduler = $app->scheduler->navigate()->verifyAndWait();
110: 
111:         // Select Location North Lorenburgh Family Office (402)
112:         $this->wait(1);
113:         $scheduler->changeLocation(402);
114: 
115:         // Select date 09/01/2016
116:         $scheduler->goToDate(new DateTime("08/01/2016"));
117:         $this->wait(1);
118: 
119:         // force scheudler to render below visible view port
120:         $scheduler->scrollTo("0900");
121:         $scheduler->scrollTo("1000");
122:         $scheduler->scrollTo("0800");
123: 
124:         // Attempt to schedule patient Selenium Self Pay at 9:00 AM
125:         // $this->querySelector("#p3552_0900 .sched_block")->click();
126:         // because IE11
127:         $this->clickElement("#p3552_0900 .sched_block");
128: 
129:         // Search for and select patient Selenium Self Pay
130:         $this->within("#find_patient_popup", function ($driver) {
131:             $driver->type("autoselect_search", "Selenium Self Pay");
132:             $driver->wait(1);
133:             $driver->waitFor('[data-grid-row="0"]')->click();
134:         });
135: 
136:         $this->waitForAjax();
137: 
138:         /**
139:          * Expected:
140:          *  a. Popup appears with text "A non-insurance patient cannot be
141:          *     scheduled on a time slot reserved for one or more insurances."
142:          *  b. There is an option to Override.
143:          */
144:         $popup = $app->popup->last();
145:         $popup->assertCanSee("A non-insurance patient cannot be scheduled on a time slot reserved for one or more insurances.");
146:         $popup->assertCanSee("Override");
147:         $popup->press("Cancel");
148: 
149:         /**
150:          * Expected:
151:          *  a. Appointment is not scheduled on the block.
152:          */
153:         $this->spinWait(function ($driver) use ($scheduler) {
154:             $driver->assertElementHasText("#p3552_0900 .sched_block", "Open");
155:             return true;
156:         });
157: 
158:         $this->assertNoErrorPopups();
159:     }
160: 
161:     /**
162:      * Summary:
163:      * Tests that an insurance patient cannot be scheduled on a slot with
164:      * insurance block restrictions that do not include any of the patient's
165:      * active insurances.
166:      */
167:     public function testCannotScheduleInsurancePatientOnInvalidInsuranceBlock()
168:     {
169:         $app = $this->login(Users::FELIX_MILLER, Users::PASSWORD);
170: 
171:         // Navigate to the Scheduler
172:         $scheduler = $app->scheduler->navigate()->verifyAndWait();
173: 
174:         // Select Location North Lorenburgh Family Office (402)
175:         $this->wait(1);
176:         $scheduler->changeLocation(402);
177: 
178:         // Select date 09/01/2016
179:         $scheduler->goToDate(new DateTime("08/01/2016"));
180:         $this->wait(1);
181: 
182:         // force scheudler to render below visible view port
183:         $scheduler->scrollTo("0900");
184:         $scheduler->scrollTo("1000");
185:         $scheduler->scrollTo("0800");
186: 
187:         // Attempt to schedule patient Selenium Primary Insurance at 9:00 AM
188:         // $this->querySelector("#p3552_0900 .sched_block")->click();
189:         // because IE11
190:         $this->clickElement("#p3552_0900 .sched_block");
191: 
192:         // Search for and select patient Selenium Primary Insurance
193:         $this->within("#find_patient_popup", function ($driver) {
194:             $driver->type("autoselect_search", "Selenium Primary Insurance");
195:             $driver->wait(1);
196:             $driver->waitFor('[data-grid-row="0"]')->click();
197:         });
198: 
199:         $this->waitForAjax();
200: 
201:         /**
202:          * Expected:
203:          *  a. Popup appears with text "The patient's insurance does not match
204:          *     the insurance(s) reserved for this appointment time slot."
205:          *  b. There is an option to Override.
206:          */
207:         $popup = $app->popup->last();
208:         $popup->assertCanSee("The patient's insurance does not match the insurance(s) reserved for this appointment time slot.");
209:         $popup->assertCanSee("Override");
210:         $popup->press("Cancel");
211: 
212:         /**
213:          * Expected:
214:          *  a. Appointment is not scheduled on the block.
215:          */
216:         $this->spinWait(function ($driver) use ($scheduler) {
217:             $driver->assertElementHasText("#p3552_0900 .sched_block", "Open");
218:             return true;
219:         });
220: 
221:         $this->assertNoErrorPopups();
222:     }
223: 
224:     /**
225:      * Summary:
226:      * Tests that an insurance patient can be scheduled on a slot with
227:      * insurance block restrictions that do not include any of the patient's
228:      * active insurances by choosing to override it - by an administrator.
229:      */
230:     public function testCanOverrideScheduleInsurancePatientOnInvalidInsuranceBlock()
231:     {
232:         $app = $this->login(Users::FELIX_MILLER, Users::PASSWORD);
233: 
234:         // Navigate to the Scheduler
235:         $scheduler = $app->scheduler->navigate()->verifyAndWait();
236: 
237:         // Select Location North Lorenburgh Family Office (402)
238:         $this->wait(1);
239:         $scheduler->changeLocation(402);
240: 
241:         // Select date 09/01/2016
242:         $scheduler->goToDate(new DateTime("08/01/2016"));
243:         $this->wait(1);
244: 
245:         // force scheudler to render below visible view port
246:         $scheduler->scrollTo("0900");
247:         $scheduler->scrollTo("1000");
248:         $scheduler->scrollTo("0800");
249: 
250:         // Attempt to schedule patient Selenium Primary Insurance at 9:00 AM
251:         // $this->querySelector("#p3552_0900 .sched_block")->click();
252:         // because IE11
253:         $this->clickElement("#p3552_0900 .sched_block");
254: 
255:         // Search for and select patient Selenium Primary Insurance
256:         $this->within("#find_patient_popup", function ($driver) {
257:             $driver->type("autoselect_search", "Selenium Primary Insurance");
258:             $driver->wait(1);
259:             $driver->waitFor('[data-grid-row="0"]')->click();
260:         });
261: 
262:         $this->waitForAjax();
263: 
264:         /**
265:          * Expected:
266:          *  a. Popup appears with text "The patient's insurance does not match
267:          *     the insurance(s) reserved for this appointment time slot."
268:          *  b. There is an option to Override.
269:          */
270:         $popup = $app->popup->last();
271:         $popup->assertCanSee("The patient's insurance does not match the insurance(s) reserved for this appointment time slot.");
272:         $popup->assertCanSee("Override");
273:         $popup->press("Override");
274: 
275:         /**
276:          * Expected:
277:          *  a. Appointment popup appears.
278:          */
279:         $popup = $scheduler->appointmentPopup->verifyAndWait();
280: 
281:         // Cancel the appointment.
282:         $app->popup->last()->press("Cancel");
283:         $this->waitForAjax();
284: 
285:         $this->assertNoErrorPopups();
286:     }
287: 
288:     /**
289:      * Summary:
290:      * Tests that an insurance patient can be scheduled on a slot with
291:      * insurance block restrictions with an insurance that matches one
292:      * of the patient's insurances.
293:      */
294:     public function testCanSchedulePatientByMatchingInsurance()
295:     {
296:         $app = $this->login(Users::FELIX_MILLER, Users::PASSWORD);
297: 
298:         // Navigate to the Scheduler
299:         $scheduler = $app->scheduler->navigate()->verifyAndWait();
300: 
301:         // Select Location North Lorenburgh Family Office (402)
302:         $this->wait(1);
303:         $scheduler->changeLocation(402);
304: 
305:         // Select date 09/01/2016
306:         $scheduler->goToDate(new DateTime("08/01/2016"));
307:         $this->wait(1);
308: 
309:         // force scheudler to render below visible view port
310:         $scheduler->scrollTo("0950");
311: 
312:         // Attempt to schedule patient Selenium Insurance Block Test at 10:00 AM
313:         // $this->querySelector("#p3552_1000 .sched_block")->click();
314:         // because IE11
315:         $this->clickElement("#p3552_1000 .sched_block");
316: 
317:         // Search for and select patient Selenium Insurance Block Test
318:         $this->within("#find_patient_popup", function ($driver) {
319:             $driver->type("autoselect_search", "Selenium Insurance Block Test");
320:             $driver->wait(1);
321:             $driver->waitFor('[data-grid-row="0"]')->click();
322:         });
323: 
324:         $this->waitForAjax();
325: 
326:         /**
327:          * Expected:
328:          *  a. Appointment popup appears.
329:          */
330:         $popup = $scheduler->appointmentPopup->verifyAndWait();
331: 
332:         // Cancel the appointment.
333:         $app->popup->last()->press("Cancel");
334:         $this->waitForAjax();
335: 
336:         $this->assertNoErrorPopups();
337:     }
338: 
339:     /**
340:      * Summary:
341:      * Tests that an insurance patient can be scheduled on a slot with
342:      * insurance block restrictions with an insurance assigned to an
343:      * insurance class that matches one of the patient's insurances.
344:      */
345:     public function testCanSchedulePatientByMatchingInsuranceClass()
346:     {
347:         $app = $this->login(Users::FELIX_MILLER, Users::PASSWORD);
348: 
349:         // Navigate to the Scheduler
350:         $scheduler = $app->scheduler->navigate()->verifyAndWait();
351: 
352:         // Select Location North Lorenburgh Family Office (402)
353:         $this->wait(1);
354:         $scheduler->changeLocation(402);
355: 
356:         // Select date 09/01/2016
357:         $scheduler->goToDate(new DateTime("08/01/2016"));
358:         $this->wait(1);
359: 
360:         // force scheudler to render below visible view port
361:         $scheduler->scrollTo("0950");
362: 
363:         // Attempt to schedule patient Selenium Ins Class Block at 10:20 AM
364:         // $this->querySelector("#p3552_1000 .sched_block")->click();
365:         // because IE11
366:         $this->clickElement("#p3552_1020 .sched_block");
367: 
368:         // Search for and select patient Selenium Ins Class Block
369:         $this->within("#find_patient_popup", function ($driver) {
370:             $driver->type("autoselect_search", "Selenium Ins Class Block");
371:             $driver->wait(1);
372:             $driver->waitFor('[data-grid-row="0"]')->click();
373:         });
374: 
375:         $this->waitForAjax();
376: 
377:         /**
378:          * Expected:
379:          *  a. Appointment popup appears.
380:          */
381:         $popup = $scheduler->appointmentPopup->verifyAndWait();
382: 
383:         // Cancel the appointment.
384:         $app->popup->last()->press("Cancel");
385:         $this->waitForAjax();
386: 
387:         $this->assertNoErrorPopups();
388:     }
389: 
390:     /**
391:      * Summary:
392:      * Tests that an insurance patient can be scheduled on a slot with
393:      * insurance block restrictions with an insurance that matches one
394:      * of the patient's insurances when scheduling in multiple appointment
395:      * mode.
396:      */
397:     public function testCanScheduleWithMultipleApptMode()
398:     {
399:         $app = $this->login(Users::FELIX_MILLER, Users::PASSWORD);
400: 
401:         // Navigate to the Scheduler
402:         $scheduler = $app->scheduler->navigate()->verifyAndWait();
403: 
404:         // Select Location North Lorenburgh Family Office (402)
405:         $this->wait(1);
406:         $scheduler->changeLocation(402);
407: 
408:         // Select date 08/01/2016
409:         $scheduler->goToDate(new DateTime("08/01/2016"));
410:         $this->wait(1);
411: 
412:         // Search for patient Selenium Insurance Block Test
413:         $app->home->search->type("search", "Selenium Insurance Block Test");
414: 
415:         // Click on autocomplete result for Selenium Insurance Block Test
416:         $this->waitFor(".autoCompleteResult")->click();
417:         $this->waitForAjax();
418: 
419:         /**
420:          * Expected:
421:          *  a. Scheduler goes into scheduling mode for
422:          *     Selenium Insurance Block Test.
423:          */
424:         $this->spinWait(function () use ($scheduler) {
425:             $scheduler->assertCanSee("Scheduling");
426:             $scheduler->assertCanSee("Selenium Insurance Block Test");
427:             return true;
428:         });
429: 
430:         // force scheudler to render below visible view port
431:         $scheduler->scrollTo("1000");
432: 
433:         // Attempt to schedule patient Selenium Insurance Block Test at 10:30 AM
434:         // with no Appointment Reason selected.
435:         // $this->querySelector("#p3552_1000 .sched_block")->click();
436:         // because IE11
437:         $this->clickElement("#p3552_1030 .sched_block");
438:         $this->waitForAjax();
439: 
440:         /**
441:          * Expected:
442:          *  a. Appointment popup appears.
443:          */
444:         $popup = $scheduler->appointmentPopup->verifyAndWait();
445: 
446:         // Cancel the appointment.
447:         $app->popup->last()->press("Cancel");
448:         $this->waitForAjax();
449: 
450:         // Select Appointment Reason "CONSULTATION" (6628)
451:         $scheduler->select("apt_are_id", 6628);
452: 
453:         // Attempt to schedule patient Selenium Insurance Block Test at 10:30 AM
454:         $this->clickElement("#p3552_1030 .sched_block");
455:         $this->waitForAjax();
456: 
457:         /**
458:          * Expected:
459:          *  a. Appointment block is scheduled with reason CONSULTATION.
460:          */
461:         $this->spinWait(function ($driver) {
462:             $driver->assertElementHasText("#p3552_1030 .sched_appointment", "Block Test, Selenium Insurance");
463:             return true;
464:         });
465: 
466:         // Click (Finish) for multi-scheduling mode
467:         $this->clickElement("#finish_sched");
468: 
469:         // Click on the newly scheduled appointment block
470:         $this->clickElement("#p3552_1030 .sched_appointment");
471:         $this->waitForAjax();
472: 
473:         /**
474:          * Expected:
475:          *  a. Appointment popup appears.
476:          *  b. Appointment Reason is set to CONSULTATION.
477:          */
478: 
479:         $popup = $scheduler->appointmentPopup->verifyAndWait();
480:         $popup->assertInputHasValue("apt_are_id", 6628);
481: 
482:         // Delete the appointment.
483:         $popup->select("apt_ast_id", 7);
484: 
485:         $app->popup->last()->press("Submit");
486:         $this->waitForAjax();
487: 
488:         $this->assertNoErrorPopups();
489:     }
490: 
491:     /**
492:      * Summary:
493:      * Tests that an insurance patient can be scheduled on a slot with
494:      * insurance block restrictions that do not match one of the patient's
495:      * insurances by overriding the restriction when scheduling in multiple
496:      * appointment mode.
497:      */
498:     public function testCanScheduleOverrideWithMultipleApptMode()
499:     {
500:         $app = $this->login(Users::FELIX_MILLER, Users::PASSWORD);
501: 
502:         // Navigate to the Scheduler
503:         $scheduler = $app->scheduler->navigate()->verifyAndWait();
504: 
505:         // Select Location North Lorenburgh Family Office (402)
506:         $this->wait(1);
507:         $scheduler->changeLocation(402);
508: 
509:         // Select date 08/01/2016
510:         $scheduler->goToDate(new DateTime("08/01/2016"));
511:         $this->wait(1);
512: 
513:         // Search for patient Selenium Primary Insurance
514:         $app->home->search->type("search", "Selenium Primary Insurance");
515: 
516:         // Click on autocomplete result for Selenium Primary Insurance
517:         $this->waitFor(".autoCompleteResult")->click();
518:         $this->waitForAjax();
519: 
520:         /**
521:          * Expected:
522:          *  a. Scheduler goes into scheduling mode for
523:          *     Selenium Primary Insurance.
524:          */
525:         $this->spinWait(function () use ($scheduler) {
526:             $scheduler->assertCanSee("Scheduling");
527:             $scheduler->assertCanSee("Selenium Primary Insurance");
528:             return true;
529:         });
530: 
531:         // force scheudler to render below visible view port
532:         $scheduler->scrollTo("1030");
533: 
534:         // Attempt to schedule patient Selenium Primary Insurance at 10:40 AM
535:         // with no Appointment Reason selected.
536:         // $this->querySelector("#p3552_1000 .sched_block")->click();
537:         // because IE11
538:         $this->clickElement("#p3552_1040 .sched_block");
539:         $this->waitForAjax();
540: 
541:         /**
542:          * Expected:
543:          *  a. Popup appears with text "The patient's insurance does not match
544:          *     the insurance(s) reserved for this appointment time slot."
545:          *  b. There is an option to Override.
546:          */
547:         $popup = $app->popup->last();
548:         $popup->assertCanSee("The patient's insurance does not match the insurance(s) reserved for this appointment time slot.");
549:         $popup->assertCanSee("Override");
550:         $popup->press("Override");
551: 
552:         /**
553:          * Expected:
554:          *  a. Appointment popup appears.
555:          */
556:         $popup = $scheduler->appointmentPopup->verifyAndWait();
557: 
558:         // Cancel the appointment.
559:         $app->popup->last()->press("Cancel");
560:         $this->waitForAjax();
561: 
562:         // Select Appointment Reason "CONSULTATION" (6628)
563:         $scheduler->select("apt_are_id", 6628);
564: 
565:         // Attempt to schedule patient Selenium Primary Insurance at 10:40 AM
566:         $this->clickElement("#p3552_1040 .sched_block");
567:         $this->waitForAjax();
568: 
569:         /**
570:          * Expected:
571:          *  a. Popup appears with text "The patient's insurance does not match
572:          *     the insurance(s) reserved for this appointment time slot."
573:          *  b. There is an option to Override.
574:          */
575:         $popup = $app->popup->last();
576:         $popup->assertCanSee("The patient's insurance does not match the insurance(s) reserved for this appointment time slot.");
577:         $popup->assertCanSee("Override");
578:         $popup->press("Override");
579: 
580:         /**
581:          * Expected:
582:          *  a. Appointment block is scheduled with reason CONSULTATION.
583:          */
584:         $this->spinWait(function ($driver) {
585:             $driver->assertElementHasText("#p3552_1040 .sched_appointment", "Primary Insurance, Selenium");
586:             return true;
587:         });
588: 
589:         // Click (Finish) for multi-scheduling mode
590:         $this->clickElement("#finish_sched");
591: 
592:         // Click on the newly scheduled appointment block
593:         $this->clickElement("#p3552_1040 .sched_appointment");
594:         $this->waitForAjax();
595: 
596:         /**
597:          * Expected:
598:          *  a. Appointment popup appears.
599:          *  b. Appointment Reason is set to CONSULTATION.
600:          */
601: 
602:         $popup = $scheduler->appointmentPopup->verifyAndWait();
603:         $popup->assertInputHasValue("apt_are_id", 6628);
604: 
605:         // Delete the appointment.
606:         $popup->select("apt_ast_id", 7);
607: 
608:         $app->popup->last()->press("Submit");
609:         $this->waitForAjax();
610: 
611:         $this->assertNoErrorPopups();
612:     }
613: }
614: 
615: ?>
API documentation generated by ApiGen