@trevordsouzabrite/test-package 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude/agents/playwright-test-generator.md +85 -0
- package/.claude/agents/playwright-test-healer.md +45 -0
- package/.claude/agents/playwright-test-planner.md +52 -0
- package/.claude/prompts/playwright-test-coverage.md +31 -0
- package/.claude/prompts/playwright-test-generate.md +12 -0
- package/.claude/prompts/playwright-test-heal.md +6 -0
- package/.claude/prompts/playwright-test-plan.md +12 -0
- package/.claude/settings.local.json +31 -0
- package/.github/agents/playwright-test-generator.agent.md +113 -0
- package/.github/agents/playwright-test-healer.agent.md +70 -0
- package/.github/agents/playwright-test-planner.agent.md +82 -0
- package/.github/prompts/playwright-test-coverage.prompt.md +31 -0
- package/.github/prompts/playwright-test-generate.prompt.md +12 -0
- package/.github/prompts/playwright-test-heal.prompt.md +6 -0
- package/.github/prompts/playwright-test-plan.prompt.md +9 -0
- package/.github/workflows/copilot-setup-steps.yml +34 -0
- package/.github/workflows/playwright-healer-agent.yml +140 -0
- package/.github/workflows/playwright.yml +40 -0
- package/.mcp.json +13 -0
- package/.vscode/extensions.json +6 -0
- package/.vscode/mcp.json +13 -0
- package/.vscode/settings.example.json +15 -0
- package/bitbucket-pipelines.yml +86 -0
- package/lib/WebActions.ts +107 -0
- package/package.json +33 -0
- package/pageRepository/ApplicantPage.ts +1171 -0
- package/pageRepository/CreateApplicationPage.ts +1736 -0
- package/playwright/.auth/user.json +0 -0
- package/specs/Applicant Create Application Page Test Plan.md +440 -0
- package/specs/Applicant Dashboard Page Test Plan.md +74 -0
- package/specs/Applicant Forgot Password Page Test Plan.md +112 -0
- package/specs/Applicant Help Page Test Plan.md +369 -0
- package/specs/Applicant Landing Page Test Plan.md +42 -0
- package/specs/Applicant Login Page Test Plan.md +116 -0
- package/specs/Applicant My Applications Page Test Plan.md +558 -0
- package/specs/Applicant My Medical Coverage Page Test Plan.md +689 -0
- package/specs/Applicant Privacy Policy Page Test Plan.md +196 -0
- package/specs/Applicant Resources Page Test Plan.md +107 -0
- package/specs/Applicant Self Register Page Test Plan.md +190 -0
- package/specs/README.md +3 -0
- package/test-data/Sample.png +0 -0
- package/test-data/createApplication/formData.json +42 -0
- package/test-data/createApplication/textMessages.json +52 -0
- package/test-data/forgotPassword/email.json +5 -0
- package/test-data/forgotPassword/textMessages.json +5 -0
- package/test-data/help/textContent.json +48 -0
- package/test-data/login/invalidUsernamePassword.json +4 -0
- package/test-data/login/textMessages.json +5 -0
- package/test-data/privacyPolicy/textContent.json +25 -0
- package/test-data/selfRegister/mailingAddressStates.json +21 -0
- package/test-data/selfRegister/registrationFieldData.json +13 -0
- package/test-data/selfRegister/suffix.json +3 -0
- package/test-data/selfRegister/textMessages.json +13 -0
- package/test-data/test-data.zip +0 -0
- package/tests/ApplicantCreateApplicationPageTest.spec.ts +1452 -0
- package/tests/ApplicantDashboardPageTest.spec.ts +74 -0
- package/tests/ApplicantForgotPasswordPageTest.spec.ts +88 -0
- package/tests/ApplicantHelpPageTest.spec.ts +468 -0
- package/tests/ApplicantLandingPageTest.spec.ts +33 -0
- package/tests/ApplicantLoginPageTest.spec.ts +117 -0
- package/tests/ApplicantMyApplicationsPageTest.spec.ts +516 -0
- package/tests/ApplicantMyMedicalCoveragePageTest.spec.ts +470 -0
- package/tests/ApplicantPrivacyPolicyPageTest.spec.ts +188 -0
- package/tests/ApplicantResourcesPageTest.spec.ts +117 -0
- package/tests/ApplicantSelfRegisterPageTest.spec.ts +254 -0
- package/tests/auth.setup.ts +42 -0
- package/tests/authState.ts +15 -0
- package/tests/example.spec.ts +18 -0
- package/tests/seed.spec.ts +7 -0
|
@@ -0,0 +1,1171 @@
|
|
|
1
|
+
import { Locator, Page, BrowserContext } from '@playwright/test';
|
|
2
|
+
import { WebActions } from '@lib/WebActions';
|
|
3
|
+
|
|
4
|
+
export class ApplicantPage {
|
|
5
|
+
readonly page: Page;
|
|
6
|
+
//readonly context: BrowserContext;
|
|
7
|
+
//readonly webActions: WebActions;
|
|
8
|
+
|
|
9
|
+
readonly Logo_Img: Locator;
|
|
10
|
+
readonly Login_Btn: Locator;
|
|
11
|
+
|
|
12
|
+
readonly WelcomeHeading_Text: Locator;
|
|
13
|
+
readonly Instructions_Text: Locator;
|
|
14
|
+
readonly Banner_Img: Locator;
|
|
15
|
+
|
|
16
|
+
readonly PolkHealthCare_Img: Locator;
|
|
17
|
+
readonly ContactUs_Lnk: Locator;
|
|
18
|
+
readonly FAQs_Lnk: Locator;
|
|
19
|
+
readonly FindYourProvider_Lnk: Locator;
|
|
20
|
+
readonly NotifyCustomerService_Lnk: Locator;
|
|
21
|
+
readonly Accessibility_Lnk: Locator;
|
|
22
|
+
readonly TermsAndConditions_Lnk: Locator;
|
|
23
|
+
readonly PrivacyPolicy_Lnk: Locator;
|
|
24
|
+
readonly Copyright_Text: Locator;
|
|
25
|
+
|
|
26
|
+
readonly LoginText_Msg: Locator;
|
|
27
|
+
readonly UsernameField_Lbl: Locator;
|
|
28
|
+
readonly UsernameField_Input: Locator;
|
|
29
|
+
readonly PasswordField_Lbl: Locator;
|
|
30
|
+
readonly PasswordField_Input: Locator;
|
|
31
|
+
readonly LoginSubmit_Btn: Locator;
|
|
32
|
+
readonly ForgotPassword_Lnk: Locator;
|
|
33
|
+
readonly SignUp_Lnk: Locator;
|
|
34
|
+
readonly ErrorMessage_Text: Locator;
|
|
35
|
+
|
|
36
|
+
readonly ForgotPasswordTitle_Text: Locator;
|
|
37
|
+
readonly ForgotPasswordMessage_Text: Locator;
|
|
38
|
+
readonly ForgotPasswordField_Lbl: Locator;
|
|
39
|
+
readonly ForgotPasswordField_Input: Locator;
|
|
40
|
+
readonly SendResetLink_Btn: Locator;
|
|
41
|
+
readonly ForgotPasswordRequiredFieldError_Text: Locator;
|
|
42
|
+
readonly ForgotPasswordSuccessMessage_Text: Locator;
|
|
43
|
+
|
|
44
|
+
readonly SelfRegisterFormTitle_Text: Locator;
|
|
45
|
+
readonly FirstNameField_Lbl: Locator;
|
|
46
|
+
readonly FirstNameField_Input: Locator;
|
|
47
|
+
readonly MiddleNameField_Lbl: Locator;
|
|
48
|
+
readonly MiddleNameField_Input: Locator;
|
|
49
|
+
readonly LastNameField_Lbl: Locator;
|
|
50
|
+
readonly LastNameField_Input: Locator;
|
|
51
|
+
readonly SuffixField_Lbl: Locator;
|
|
52
|
+
|
|
53
|
+
readonly SuffixField_dd: Locator;
|
|
54
|
+
readonly SuffixField_ddl: Locator;
|
|
55
|
+
readonly DOBField_Lbl: Locator;
|
|
56
|
+
readonly DOBField_Input: Locator;
|
|
57
|
+
readonly DOBField_DatePicker: Locator;
|
|
58
|
+
readonly EmailField_Lbl: Locator;
|
|
59
|
+
readonly EmailField_Input: Locator;
|
|
60
|
+
readonly Agreement_Text:Locator;
|
|
61
|
+
readonly Register_Btn: Locator;
|
|
62
|
+
|
|
63
|
+
readonly PhysicalAddress_Section: Locator;
|
|
64
|
+
readonly PhysicalAddress_Title: Locator;
|
|
65
|
+
readonly PhysicalAddress_AddressField: Locator;
|
|
66
|
+
readonly PhysicalAddress_Response_ddl: Locator;
|
|
67
|
+
readonly PhysicalAddress_CountryField_Lbl: Locator;
|
|
68
|
+
readonly PhysicalAddress_CountryField_dd: Locator;
|
|
69
|
+
readonly PhysicalAddress_CountryField_ddl: Locator;
|
|
70
|
+
readonly PhysicalAddress_StreetField_Lbl: Locator;
|
|
71
|
+
readonly PhysicalAddress_StreetField_Input: Locator;
|
|
72
|
+
readonly PhysicalAddress_CityField_Lbl: Locator;
|
|
73
|
+
readonly PhysicalAddress_CityField_Input: Locator;
|
|
74
|
+
readonly PhysicalAddress_StateField_Lbl: Locator;
|
|
75
|
+
readonly PhysicalAddress_StateField_dd: Locator;
|
|
76
|
+
readonly PhysicalAddress_StateField_ddl: Locator;
|
|
77
|
+
readonly PhysicalAddress_Zip_Lbl:Locator;
|
|
78
|
+
readonly PhysicalAddress_Zip_Input:Locator;
|
|
79
|
+
readonly PhysicalAddress_FieldError_Text: Locator;
|
|
80
|
+
|
|
81
|
+
readonly MailingAddress_Section: Locator;
|
|
82
|
+
readonly MailingAddress_Title: Locator;
|
|
83
|
+
readonly MailingAddress_SameAsPhysical_Toggle: Locator;
|
|
84
|
+
readonly MailingAddress_AddressField: Locator;
|
|
85
|
+
readonly MailingAddress_Response_ddl: Locator;
|
|
86
|
+
readonly MailingAddress_CountryField_Lbl: Locator;
|
|
87
|
+
readonly MailingAddress_CountryField_dd: Locator;
|
|
88
|
+
readonly MailingAddress_CountryField_ddl: Locator;
|
|
89
|
+
readonly MailingAddress_StreetField_Lbl: Locator;
|
|
90
|
+
readonly MailingAddress_StreetField_Input: Locator;
|
|
91
|
+
readonly MailingAddress_CityField_Lbl: Locator;
|
|
92
|
+
readonly MailingAddress_CityField_Input: Locator;
|
|
93
|
+
readonly MailingAddress_StateField_Lbl: Locator;
|
|
94
|
+
readonly MailingAddress_StateField_dd: Locator;
|
|
95
|
+
readonly MailingAddress_StateField_ddl: Locator;
|
|
96
|
+
readonly MailingAddress_Zip_Lbl:Locator;
|
|
97
|
+
readonly MailingAddress_Zip_Input:Locator;
|
|
98
|
+
readonly MailingAddress_FieldError_Text: Locator;
|
|
99
|
+
readonly SuccessPage_Text: Locator;
|
|
100
|
+
|
|
101
|
+
readonly Home_Lnk: Locator;
|
|
102
|
+
readonly CreateApplication_Lnk: Locator;
|
|
103
|
+
readonly MyApplication_Lnk: Locator;
|
|
104
|
+
readonly MyMedicalCoverage_Lnk: Locator;
|
|
105
|
+
readonly Resources_Lnk: Locator;
|
|
106
|
+
readonly Help_Lnk: Locator;
|
|
107
|
+
readonly PrivacyPolicyHeader_Lnk: Locator;
|
|
108
|
+
readonly Logout_Btn: Locator;
|
|
109
|
+
|
|
110
|
+
/** Post-login modal when a new consent form version requires re-signing. */
|
|
111
|
+
readonly ConsentFormUpdateRequired_Heading: Locator;
|
|
112
|
+
readonly ReSignConsentForm_Button: Locator;
|
|
113
|
+
/** Standalone portal consent page (/consent) — English or Spanish labels. */
|
|
114
|
+
readonly PortalConsentInformation_ChkBox: Locator;
|
|
115
|
+
readonly PortalConsentSignature_Canvas: Locator;
|
|
116
|
+
readonly PortalAcceptSignature_Button: Locator;
|
|
117
|
+
readonly PortalAgreeAndConsent_Button: Locator;
|
|
118
|
+
|
|
119
|
+
readonly CreateApplicationTitle_Text: Locator;
|
|
120
|
+
|
|
121
|
+
readonly MyApplications_Table: Locator;
|
|
122
|
+
readonly MyApplicationsHeading_Text: Locator;
|
|
123
|
+
readonly MyApplicationsRecentlyViewed_Text: Locator;
|
|
124
|
+
readonly MyApplicationsListSummary_Text: Locator;
|
|
125
|
+
readonly MyApplicationsRows_All: Locator;
|
|
126
|
+
readonly MyApplicationsFirstRow_Block: Locator;
|
|
127
|
+
readonly MyApplicationsFirstApplication_Lnk: Locator;
|
|
128
|
+
readonly MyApplicationsSearch_Input: Locator;
|
|
129
|
+
readonly MyApplicationsClearSearch_Btn: Locator;
|
|
130
|
+
readonly MyApplicationsNoItems_Text: Locator;
|
|
131
|
+
readonly MyApplicationsSearchHelper_Text: Locator;
|
|
132
|
+
readonly MyApplicationsNameColumnHeader_Btn: Locator;
|
|
133
|
+
readonly MyApplicationsLastModifiedDateColumnHeader_Btn: Locator;
|
|
134
|
+
readonly MyApplicationsLastModifiedDateColumnActions_Btn: Locator;
|
|
135
|
+
readonly MyApplicationsWrapText_MenuItem: Locator;
|
|
136
|
+
readonly MyApplicationsClipText_MenuItem: Locator;
|
|
137
|
+
readonly MyApplicationsFirstRowActions_Btn: Locator;
|
|
138
|
+
readonly MyApplicationsEdit_MenuItem: Locator;
|
|
139
|
+
readonly MyApplicationsEditDialog_Block: Locator;
|
|
140
|
+
readonly MyApplicationsListViewSelector_Btn: Locator;
|
|
141
|
+
readonly MyApplicationsAllApplications_MenuItem: Locator;
|
|
142
|
+
readonly MyApplicationsAppealedApplications_MenuItem: Locator;
|
|
143
|
+
readonly MyApplicationsRecentlyViewed_MenuItem: Locator;
|
|
144
|
+
readonly MyApplicationsWithPriorityIndicator_MenuItem: Locator;
|
|
145
|
+
readonly MyApplicationsListViewControls_Btn: Locator;
|
|
146
|
+
readonly MyApplicationsNew_MenuItem: Locator;
|
|
147
|
+
readonly MyApplicationsClone_MenuItem: Locator;
|
|
148
|
+
readonly MyApplicationsRename_MenuItem: Locator;
|
|
149
|
+
readonly MyApplicationsSharingSettings_MenuItem: Locator;
|
|
150
|
+
readonly MyApplicationsSelectFieldsToDisplay_MenuItem: Locator;
|
|
151
|
+
readonly MyApplicationsDelete_MenuItem: Locator;
|
|
152
|
+
readonly MyApplicationsResetColumnWidths_MenuItem: Locator;
|
|
153
|
+
readonly MyApplicationsRefresh_Btn: Locator;
|
|
154
|
+
readonly MyApplicationsCharts_Btn: Locator;
|
|
155
|
+
readonly MyApplicationsFilters_Btn: Locator;
|
|
156
|
+
readonly MyApplicationsColumnHeaders_Block: Locator;
|
|
157
|
+
readonly MyApplicationsTableBody_Block: Locator;
|
|
158
|
+
readonly ApplicationRecordHeader_Text: Locator;
|
|
159
|
+
readonly ApplicationRecordName_Heading: Locator;
|
|
160
|
+
readonly ApplicationRecordStatus_Text: Locator;
|
|
161
|
+
readonly ApplicationRecordApplicationTotalFPL_Text: Locator;
|
|
162
|
+
readonly ApplicationRecordReviewTotalFPL_Text: Locator;
|
|
163
|
+
readonly ApplicationRecordTotalHouseholdMonthlyIncome_Text: Locator;
|
|
164
|
+
readonly ApplicationRecordReviewerTotalHouseholdIncome_Text: Locator;
|
|
165
|
+
readonly ApplicationRecordPendingWarning_Text: Locator;
|
|
166
|
+
readonly ApplicationRecordDetailsTab_Btn: Locator;
|
|
167
|
+
readonly ApplicationRecordRelatedTab_Btn: Locator;
|
|
168
|
+
readonly ApplicationRecordResumeApplication_Btn: Locator;
|
|
169
|
+
readonly ApplicationRecordScheduleAppointment_Btn: Locator;
|
|
170
|
+
readonly ApplicationRecordRequestAppeal_Btn: Locator;
|
|
171
|
+
readonly ApplicationRecordSubmitDate_Text: Locator;
|
|
172
|
+
readonly ApplicationRecordAssignedDate_Text: Locator;
|
|
173
|
+
readonly ApplicationRecordOwnerName_Text: Locator;
|
|
174
|
+
readonly ApplicationRecordEndDate_Text: Locator;
|
|
175
|
+
readonly ApplicationRecordHouseholdNumber_Text: Locator;
|
|
176
|
+
readonly ApplicationRecordHouseholdMembers_Text: Locator;
|
|
177
|
+
readonly ApplicationRecordSocialServices_Text: Locator;
|
|
178
|
+
readonly ApplicationRecordRelatedContent_Block: Locator;
|
|
179
|
+
readonly ApplicationRecordDialog_Block: Locator;
|
|
180
|
+
readonly ApplicationDetailsTab: Locator;
|
|
181
|
+
|
|
182
|
+
readonly MyMedicalCoverageRecords: Locator;
|
|
183
|
+
readonly NoEnrollments_Text: Locator;
|
|
184
|
+
readonly MyMedicalCoverageBody_Block: Locator;
|
|
185
|
+
readonly MyMedicalCoverageBeneficiaryHeader_Text: Locator;
|
|
186
|
+
readonly MyMedicalCoverageProgramHeader_Text: Locator;
|
|
187
|
+
readonly MyMedicalCoverageStatusHeader_Text: Locator;
|
|
188
|
+
readonly MyMedicalCoverageCoverageBeginDateHeader_Text: Locator;
|
|
189
|
+
readonly MyMedicalCoverageCoverageEndDateHeader_Text: Locator;
|
|
190
|
+
readonly MyMedicalCoverageActionsHeader_Text: Locator;
|
|
191
|
+
readonly MyMedicalCoverageFirstEnrollmentRow_Block: Locator;
|
|
192
|
+
readonly MyMedicalCoverageChangeProvider_Btn: Locator;
|
|
193
|
+
readonly MyMedicalCoverageEnrollmentCard_Btn: Locator;
|
|
194
|
+
readonly MyMedicalCoverageUpdateMyInformation_Btn: Locator;
|
|
195
|
+
readonly MyMedicalCoverageBillingInquiries_Btn: Locator;
|
|
196
|
+
readonly MyMedicalCoverageRequestStatusHeading_Text: Locator;
|
|
197
|
+
readonly MyMedicalCoverageRequestStatus_Block: Locator;
|
|
198
|
+
readonly MyMedicalCoverageRequestStatusStatus_Text: Locator;
|
|
199
|
+
readonly MyMedicalCoverageRequestStatusEffectiveDate_Text: Locator;
|
|
200
|
+
readonly MyMedicalCoverageRequestStatusReference_Text: Locator;
|
|
201
|
+
readonly ChangeProviderDialog_Block: Locator;
|
|
202
|
+
readonly ChangeProviderHeading_Text: Locator;
|
|
203
|
+
readonly ChangeProviderInstructions_Text: Locator;
|
|
204
|
+
readonly ChangeProviderSearch_Input: Locator;
|
|
205
|
+
readonly ChangeProviderReason_dd: Locator;
|
|
206
|
+
readonly ChangeProviderClose_Btn: Locator;
|
|
207
|
+
readonly ChangeProviderSubmit_Btn: Locator;
|
|
208
|
+
readonly ChangeProviderRequiredFieldErrors_Text: Locator;
|
|
209
|
+
readonly ChangeProviderErrorNotification_Text: Locator;
|
|
210
|
+
readonly EnrollmentCardPage_Text: Locator;
|
|
211
|
+
readonly UpdateMyInformationErrorToast_Text: Locator;
|
|
212
|
+
readonly ToastClose_Btn: Locator;
|
|
213
|
+
readonly BillingInquiryHeading_Text: Locator;
|
|
214
|
+
readonly BillingInquiryInstructions_Text: Locator;
|
|
215
|
+
readonly BillingInquiryCoverageReason_Text: Locator;
|
|
216
|
+
readonly BillingInquiryDateOfService_Input: Locator;
|
|
217
|
+
readonly BillingInquiryAmountDue_Input: Locator;
|
|
218
|
+
readonly BillingInquiryOtherPayer_dd: Locator;
|
|
219
|
+
readonly BillingInquiryUploadFiles_Btn: Locator;
|
|
220
|
+
readonly BillingInquiryUploadDropzone_Text: Locator;
|
|
221
|
+
readonly BillingInquiryApplicationMember_dd: Locator;
|
|
222
|
+
readonly BillingInquiryAppealReason_dd: Locator;
|
|
223
|
+
readonly BillingInquiryProviderFacilityName_Input: Locator;
|
|
224
|
+
readonly BillingInquiryClaimNumber_Input: Locator;
|
|
225
|
+
readonly BillingInquiryAmountPaidByOtherProvider_Input: Locator;
|
|
226
|
+
readonly BillingInquiryDocumentType_dd: Locator;
|
|
227
|
+
readonly BillingInquiryCancel_Btn: Locator;
|
|
228
|
+
readonly BillingInquirySubmit_Btn: Locator;
|
|
229
|
+
readonly BillingInquiryUploadRequiredToast_Text: Locator;
|
|
230
|
+
|
|
231
|
+
readonly ResourcesTitle_Text: Locator;
|
|
232
|
+
readonly PolkHealthCarePlanMemberHandbook_Lnk: Locator;
|
|
233
|
+
readonly UniversalHouseholdAuthorizationForm_Lnk: Locator;
|
|
234
|
+
readonly UniversalSharedDataInformationSystem_Lnk: Locator;
|
|
235
|
+
readonly EligibilityIncomeVerificationStatement_Lnk: Locator;
|
|
236
|
+
readonly ThirdPartySupport_Lnk: Locator;
|
|
237
|
+
|
|
238
|
+
// Help Page Locators
|
|
239
|
+
readonly KnowledgeBaseH1_Text: Locator;
|
|
240
|
+
readonly KnowledgeBaseSubtitle_Text: Locator;
|
|
241
|
+
readonly KnowledgeBaseSearch_Input: Locator;
|
|
242
|
+
readonly KnowledgeBaseSearchClear_Btn: Locator;
|
|
243
|
+
readonly KnowledgeBaseCategoryAll_Lnk: Locator;
|
|
244
|
+
readonly KnowledgeBaseCategorySupport_Lnk: Locator;
|
|
245
|
+
readonly KnowledgeBaseCategoryAccount_Lnk: Locator;
|
|
246
|
+
readonly KnowledgeBaseCategoryGeneral_Lnk: Locator;
|
|
247
|
+
readonly KnowledgeBaseTypeAll_Lnk: Locator;
|
|
248
|
+
readonly KnowledgeBaseTypeFaq_Lnk: Locator;
|
|
249
|
+
readonly KnowledgeBaseTypeProcedure_Lnk: Locator;
|
|
250
|
+
readonly KnowledgeBaseArticleCards_All: Locator;
|
|
251
|
+
readonly KnowledgeBaseFirstCardBadge_Text: Locator;
|
|
252
|
+
readonly KnowledgeBaseFirstCardTitle_Text: Locator;
|
|
253
|
+
readonly KnowledgeBaseFirstCardSummary_Text: Locator;
|
|
254
|
+
readonly KnowledgeBaseFirstCardDate_Text: Locator;
|
|
255
|
+
readonly KnowledgeBaseFirstCardReadMore_Lnk: Locator;
|
|
256
|
+
readonly KnowledgeBaseEmptyState_Text: Locator;
|
|
257
|
+
readonly KnowledgeBaseH1_All: Locator;
|
|
258
|
+
readonly KnowledgeBaseH1Role_Heading: Locator;
|
|
259
|
+
readonly KnowledgeBaseH2_All: Locator;
|
|
260
|
+
readonly KnowledgeBaseH3_All: Locator;
|
|
261
|
+
readonly ArticleDetailH1_Text: Locator;
|
|
262
|
+
readonly ArticleDetailBadge_Text: Locator;
|
|
263
|
+
readonly ArticleDetailPublished_Text: Locator;
|
|
264
|
+
readonly ArticleDetailCategory_Text: Locator;
|
|
265
|
+
readonly ArticleDetailArticleNumber_Text: Locator;
|
|
266
|
+
readonly ArticleDetailSummaryLabel_Text: Locator;
|
|
267
|
+
readonly ArticleDetailSummaryContent_Text: Locator;
|
|
268
|
+
readonly ArticleDetailAudienceLabel_Text: Locator;
|
|
269
|
+
readonly ArticleDetailAudienceContent_Text: Locator;
|
|
270
|
+
readonly ArticleDetailPurposeLabel_Text: Locator;
|
|
271
|
+
readonly ArticleDetailPurposeContent_Text: Locator;
|
|
272
|
+
readonly ArticleDetailWarningBlock_Text: Locator;
|
|
273
|
+
readonly ArticleDetailStepsLabel_Text: Locator;
|
|
274
|
+
readonly ArticleDetailStepsContent_Block: Locator;
|
|
275
|
+
readonly ArticleDetailHelpfulLabel_Text: Locator;
|
|
276
|
+
readonly ArticleDetailHelpfulYes_Btn: Locator;
|
|
277
|
+
readonly ArticleDetailHelpfulNo_Btn: Locator;
|
|
278
|
+
readonly ArticleDetailBackToKB_Btn: Locator;
|
|
279
|
+
readonly ArticleDetailBanner_Img: Locator;
|
|
280
|
+
|
|
281
|
+
// Privacy Policy Page Locators
|
|
282
|
+
readonly PrivacyPolicyTitle_Text: Locator;
|
|
283
|
+
readonly RegistrationInformationHeading_Text: Locator;
|
|
284
|
+
readonly HowPolkCountyUsesYourInformationHeading_Text: Locator;
|
|
285
|
+
readonly PrivacyPolicyFirstParagraph_Text: Locator;
|
|
286
|
+
readonly PrivacyPolicySMSNoticeParagraph_Text: Locator;
|
|
287
|
+
readonly PrivacyPolicySMSNoticeBold_Lbl: Locator;
|
|
288
|
+
readonly PrivacyPolicyHowPolkIntroParagraph_Text: Locator;
|
|
289
|
+
readonly PrivacyPolicyList_Ul: Locator;
|
|
290
|
+
readonly PrivacyPolicyListItems_Li: Locator;
|
|
291
|
+
readonly PrivacyPolicyClosingParagraph_Text: Locator;
|
|
292
|
+
readonly PrivacyPolicyH1_All: Locator;
|
|
293
|
+
readonly PrivacyPolicyH1Role_Heading: Locator;
|
|
294
|
+
readonly PrivacyPolicyH2_All: Locator;
|
|
295
|
+
readonly PrivacyPolicyH3_All: Locator;
|
|
296
|
+
readonly HtmlRoot_Elem: Locator;
|
|
297
|
+
|
|
298
|
+
constructor(page: Page) {
|
|
299
|
+
this.page = page;
|
|
300
|
+
//Header Section Locators
|
|
301
|
+
this.Logo_Img = page.getByRole('img', { name: 'Logo' });
|
|
302
|
+
this.Login_Btn = page.locator('.bar .btn');
|
|
303
|
+
|
|
304
|
+
// Heading & Content Section Locators
|
|
305
|
+
this.WelcomeHeading_Text = page.getByRole('heading', { name: 'Welcome to the Polk HealthCare Plan Applicant Portal' });
|
|
306
|
+
this.Instructions_Text = page.locator('//div[@class="uiOutputRichText"]//div//div[2]')
|
|
307
|
+
this.Banner_Img = page.getByRole('img', { name: 'Banner' });
|
|
308
|
+
|
|
309
|
+
//Footer Section Locators
|
|
310
|
+
this.PolkHealthCare_Img = page.getByRole('img', { name: 'Polk HealthCare Plan' });
|
|
311
|
+
this.ContactUs_Lnk = page.getByRole('link', { name: 'CONTACT US' });
|
|
312
|
+
this.FAQs_Lnk = page.getByRole('link', { name: 'POLK HEALTHCARE PLAN FAQS' });
|
|
313
|
+
this.FindYourProvider_Lnk = page.getByRole('link', { name: 'FIND YOUR PROVIDER' });
|
|
314
|
+
this.NotifyCustomerService_Lnk = page.getByRole('link', { name: 'NOTIFY CUSTOMER SERVICE' });
|
|
315
|
+
this.Accessibility_Lnk = page.getByRole('link', { name: 'ACCESSIBILITY' });
|
|
316
|
+
this.TermsAndConditions_Lnk = page.getByRole('link', { name: 'TERMS & CONDITIONS' });
|
|
317
|
+
this.PrivacyPolicy_Lnk = page.getByText('PRIVACY POLICY', { exact: true });
|
|
318
|
+
this.Copyright_Text = page.getByText('Copyright © 2025 Polk County');
|
|
319
|
+
|
|
320
|
+
//Login Page Locators
|
|
321
|
+
this.LoginText_Msg = page.locator('.uiOutputRichText > div');
|
|
322
|
+
this.UsernameField_Lbl = page.getByText('*UserName');
|
|
323
|
+
this.UsernameField_Input = page.getByRole('textbox', { name: 'UserName' });
|
|
324
|
+
this.PasswordField_Lbl = page.getByText('*Password');
|
|
325
|
+
this.PasswordField_Input = page.getByRole('textbox', { name: 'Password' });
|
|
326
|
+
this.LoginSubmit_Btn = page.locator('.login-btn').nth(0);
|
|
327
|
+
this.ForgotPassword_Lnk = page.getByRole('link', { name: 'Forgot Password?' });
|
|
328
|
+
this.SignUp_Lnk = page.getByRole('link', { name: 'Sign Up' });
|
|
329
|
+
this.ErrorMessage_Text = page.locator('.error');
|
|
330
|
+
|
|
331
|
+
//Forgot Password Page Locators
|
|
332
|
+
this.ForgotPasswordTitle_Text = page.locator('.card .title');
|
|
333
|
+
this.ForgotPasswordMessage_Text = page.locator('.card .sub');
|
|
334
|
+
this.ForgotPasswordField_Lbl = page.getByLabel('Email / Username');
|
|
335
|
+
this.ForgotPasswordField_Input = page.getByRole('textbox', { name: 'Email / Username' });
|
|
336
|
+
this.SendResetLink_Btn = page.getByRole('button', { name: 'Send reset link' });
|
|
337
|
+
this.ForgotPasswordRequiredFieldError_Text = page.locator(".slds-has-error .slds-form-element__help");
|
|
338
|
+
this.ForgotPasswordSuccessMessage_Text = page.locator('div.msg.success');
|
|
339
|
+
|
|
340
|
+
//Self Register Page Locators
|
|
341
|
+
this.SelfRegisterFormTitle_Text = page.getByRole('heading', { name: 'Self Registration' });
|
|
342
|
+
//this.FirstNameField_Text = page.getByText('*Applicant First Name');
|
|
343
|
+
this.FirstNameField_Lbl = page.locator("//lightning-input[@data-id='firstName']")
|
|
344
|
+
this.FirstNameField_Input = page.getByRole('textbox', { name: 'Applicant First Name' });
|
|
345
|
+
this.MiddleNameField_Lbl = page.getByText('Applicant Middle Name');
|
|
346
|
+
this.MiddleNameField_Input = page.getByRole('textbox', { name: 'Applicant Middle Name' });
|
|
347
|
+
this.LastNameField_Lbl = page.locator("//lightning-input[@data-id='lastName']");
|
|
348
|
+
this.LastNameField_Input = page.getByRole('textbox', { name: 'Applicant Last Name' });
|
|
349
|
+
this.SuffixField_Lbl = page.getByText('Suffix', { exact: true });
|
|
350
|
+
|
|
351
|
+
this.SuffixField_dd = page.getByRole('combobox', { name: 'Suffix' });
|
|
352
|
+
this.SuffixField_ddl = page.getByRole('listbox', { name: 'Suffix' });
|
|
353
|
+
this.DOBField_Lbl = page.getByLabel('Date of Birth MM-dd-yyyy', { exact: true });
|
|
354
|
+
this.DOBField_Input = page.getByRole('textbox', { name: 'Date of Birth MM-dd-yyyy' });
|
|
355
|
+
this.DOBField_DatePicker = page.locator('lightning-focus-trap');
|
|
356
|
+
this.EmailField_Lbl = page.locator("//lightning-input[@data-id='email']");
|
|
357
|
+
this.EmailField_Input = page.getByRole('textbox', { name: 'Email Address' });
|
|
358
|
+
this.Agreement_Text = page.locator("div[class='slds-m-around_medium'] p")
|
|
359
|
+
this.Register_Btn = page.getByRole('button', { name: 'Register' });
|
|
360
|
+
|
|
361
|
+
//Self Register Page Locators - Physical Address
|
|
362
|
+
this.PhysicalAddress_Section = page.locator('section.card').nth(0);
|
|
363
|
+
this.PhysicalAddress_Title = page.getByRole('heading', { name: 'Physical Address' });
|
|
364
|
+
this.PhysicalAddress_AddressField = page.locator('lightning-lookup-address input[role="combobox"]').first();
|
|
365
|
+
this.PhysicalAddress_Response_ddl = page.locator('span.slds-media__body')
|
|
366
|
+
this.PhysicalAddress_CountryField_Lbl = page.locator('label').filter({ hasText: 'Country' }).first();
|
|
367
|
+
this.PhysicalAddress_CountryField_dd = page.getByRole('combobox', { name: 'Country' }).first();
|
|
368
|
+
this.PhysicalAddress_CountryField_ddl = page.getByRole('listbox', { name: 'Country' }).first();
|
|
369
|
+
this.PhysicalAddress_StreetField_Lbl = page.getByText('Street').first();
|
|
370
|
+
this.PhysicalAddress_StreetField_Input = page.getByRole('textbox', { name: 'Street' }).first();
|
|
371
|
+
this.PhysicalAddress_CityField_Lbl = page.getByText('City').first();
|
|
372
|
+
this.PhysicalAddress_CityField_Input = page.getByRole('textbox', { name: 'City' }).first();
|
|
373
|
+
this.PhysicalAddress_StateField_Lbl = page.locator('label').filter({ hasText: 'State' }).first();
|
|
374
|
+
this.PhysicalAddress_StateField_dd = page.getByRole('combobox', { name: 'State' }).first();
|
|
375
|
+
this.PhysicalAddress_StateField_ddl = page.getByRole('listbox', { name: 'State' }).first();
|
|
376
|
+
this.PhysicalAddress_Zip_Lbl = page.getByText('ZIP').first()
|
|
377
|
+
this.PhysicalAddress_Zip_Input = page.getByRole('textbox', { name: 'ZIP' }).first();
|
|
378
|
+
this.PhysicalAddress_FieldError_Text = page.locator('div.error').first();
|
|
379
|
+
|
|
380
|
+
//Self Register Page Locators - Mailing Address
|
|
381
|
+
this.MailingAddress_Section = page.locator('section.card').nth(1);
|
|
382
|
+
this.MailingAddress_Title = page.getByRole('heading', { name: 'Mailing Address' });
|
|
383
|
+
//this.MailingAddress_SameAsPhysical_Text = page.getByLabel('Same as Physical');
|
|
384
|
+
this.MailingAddress_SameAsPhysical_Toggle = page.locator('lightning-input:has-text("Same as Physical")');
|
|
385
|
+
this.MailingAddress_AddressField = page.locator('lightning-lookup-address input[role="combobox"]').last();
|
|
386
|
+
this.MailingAddress_Response_ddl = page.locator('span.slds-media__body')
|
|
387
|
+
this.MailingAddress_CountryField_Lbl = page.locator('label').filter({ hasText: 'Country' }).last();
|
|
388
|
+
this.MailingAddress_CountryField_dd = page.getByRole('combobox', { name: 'Country' }).last();
|
|
389
|
+
this.MailingAddress_CountryField_ddl = page.getByRole('listbox', { name: 'Country' }).last();
|
|
390
|
+
this.MailingAddress_StreetField_Lbl = page.getByText('Street').last();
|
|
391
|
+
this.MailingAddress_StreetField_Input = page.getByRole('textbox', { name: 'Street' }).last();
|
|
392
|
+
this.MailingAddress_CityField_Lbl = page.getByText('City').last();
|
|
393
|
+
this.MailingAddress_CityField_Input = page.getByRole('textbox', { name: 'City' }).last();
|
|
394
|
+
this.MailingAddress_StateField_Lbl = page.locator('label').filter({ hasText: 'State' }).last();
|
|
395
|
+
this.MailingAddress_StateField_dd = page.getByRole('combobox', { name: 'State' }).last();
|
|
396
|
+
this.MailingAddress_StateField_ddl = page.getByRole('listbox', { name: 'State' }).last();
|
|
397
|
+
this.MailingAddress_Zip_Lbl = page.getByText('ZIP').last()
|
|
398
|
+
this.MailingAddress_Zip_Input = page.getByRole('textbox', { name: 'ZIP' }).last()
|
|
399
|
+
this.MailingAddress_FieldError_Text = page.locator('div.error').last();
|
|
400
|
+
|
|
401
|
+
this.SuccessPage_Text = page.locator('strong:visible');
|
|
402
|
+
|
|
403
|
+
//Applicant Portal
|
|
404
|
+
this.Home_Lnk = page.getByRole('link', { name: 'Home', exact: true });
|
|
405
|
+
this.CreateApplication_Lnk = page.getByRole('link', { name: 'Create Application' });
|
|
406
|
+
this.MyApplication_Lnk = page.getByRole('link', { name: 'My Application' });
|
|
407
|
+
this.MyMedicalCoverage_Lnk = page.getByRole('link', { name: 'My Medical Coverage' });
|
|
408
|
+
this.Resources_Lnk = page.getByRole('link', { name: 'Resources' });
|
|
409
|
+
this.Help_Lnk = page.getByRole('link', { name: 'Help' })
|
|
410
|
+
this.PrivacyPolicyHeader_Lnk = page.getByRole('link', { name: 'Privacy Policy', exact: true });
|
|
411
|
+
this.Logout_Btn = page.getByRole('button', { name: 'Logout' });
|
|
412
|
+
|
|
413
|
+
this.ConsentFormUpdateRequired_Heading = page.getByRole('heading', {
|
|
414
|
+
name: /Consent Form Update Required/i,
|
|
415
|
+
});
|
|
416
|
+
this.ReSignConsentForm_Button = page.getByRole('button', { name: 'Re-sign Consent Form' });
|
|
417
|
+
this.PortalConsentInformation_ChkBox = page.getByText(
|
|
418
|
+
/I have read and agree to the consent information\.|He leído y acepto la información del consentimiento\./,
|
|
419
|
+
);
|
|
420
|
+
this.PortalConsentSignature_Canvas = page.locator('canvas.sigCanvas');
|
|
421
|
+
this.PortalAcceptSignature_Button = page.getByRole('button', {
|
|
422
|
+
name: /Accept Signature|Aceptar Firma/i,
|
|
423
|
+
});
|
|
424
|
+
this.PortalAgreeAndConsent_Button = page.getByRole('button', {
|
|
425
|
+
name: /Agree and Consent|Aceptar y Dar Consentimiento/i,
|
|
426
|
+
});
|
|
427
|
+
|
|
428
|
+
//Create Application Page Locators
|
|
429
|
+
this.CreateApplicationTitle_Text = page.locator('strong:has-text("Demographics")');
|
|
430
|
+
//My Applications Page Locators
|
|
431
|
+
this.MyApplications_Table = page.locator('div.test-listViewManager.slds-card.slds-card_boundary.slds-grid.slds-grid_vertical.slds-grid--vertical.forceListViewManager.forceCommunityRecordListDesktop.forceCommunityObjectHome');
|
|
432
|
+
this.MyApplicationsHeading_Text = page.getByRole('heading', { name: 'Applications', exact: true });
|
|
433
|
+
this.MyApplicationsRecentlyViewed_Text = page.getByText('Recently Viewed', { exact: true }).first();
|
|
434
|
+
this.MyApplicationsListSummary_Text = page.locator('.slds-page-header__meta-text').filter({ hasText: /items?|Updated/i }).first();
|
|
435
|
+
this.MyApplicationsRows_All = this.MyApplications_Table.locator('tbody tr');
|
|
436
|
+
this.MyApplicationsFirstRow_Block = this.MyApplicationsRows_All.first();
|
|
437
|
+
this.MyApplicationsFirstApplication_Lnk = this.MyApplications_Table.locator('tbody a[href*="/careprogram/"]').first();
|
|
438
|
+
this.MyApplicationsSearch_Input = page.getByPlaceholder('Search this list...');
|
|
439
|
+
this.MyApplicationsClearSearch_Btn = page.getByRole('button', { name: 'Clear' });
|
|
440
|
+
this.MyApplicationsNoItems_Text = page.getByText('No items to display.');
|
|
441
|
+
this.MyApplicationsSearchHelper_Text = page.getByText(/Last Modified By|Last Modified Date|Parent Program|Program Sponsor/);
|
|
442
|
+
this.MyApplicationsNameColumnHeader_Btn = page.getByRole('button', { name: /Name/i }).first();
|
|
443
|
+
this.MyApplicationsLastModifiedDateColumnHeader_Btn = page.getByRole('button', { name: /Last Modified Date/i }).first();
|
|
444
|
+
this.MyApplicationsLastModifiedDateColumnActions_Btn = page.getByRole('button', { name: /Show Last Modified Date Column Actions/i });
|
|
445
|
+
this.MyApplicationsWrapText_MenuItem = page.getByRole('menuitem', { name: /Wrap text/i });
|
|
446
|
+
this.MyApplicationsClipText_MenuItem = page.getByRole('menuitem', { name: /Clip text/i });
|
|
447
|
+
this.MyApplicationsFirstRowActions_Btn = page.getByRole('button', { name: /Show Actions/i }).first();
|
|
448
|
+
this.MyApplicationsEdit_MenuItem = page.getByRole('menuitem', { name: /^Edit$/i });
|
|
449
|
+
this.MyApplicationsEditDialog_Block = page.locator('.slds-modal:visible, [role="dialog"]:visible').first();
|
|
450
|
+
this.MyApplicationsListViewSelector_Btn = page.getByRole('button', { name: /Select a List View/i });
|
|
451
|
+
this.MyApplicationsAllApplications_MenuItem = page.getByRole('option', { name: 'All Applications' }).or(page.getByRole('menuitem', { name: 'All Applications' }));
|
|
452
|
+
this.MyApplicationsAppealedApplications_MenuItem = page.getByRole('option', { name: 'Appealed Applications' }).or(page.getByRole('menuitem', { name: 'Appealed Applications' }));
|
|
453
|
+
this.MyApplicationsRecentlyViewed_MenuItem = page.getByRole('option', { name: 'Recently Viewed' }).or(page.getByRole('menuitem', { name: 'Recently Viewed' }));
|
|
454
|
+
this.MyApplicationsWithPriorityIndicator_MenuItem = page.getByRole('option', { name: 'With Priority Indicator' }).or(page.getByRole('menuitem', { name: 'With Priority Indicator' }));
|
|
455
|
+
this.MyApplicationsListViewControls_Btn = page.getByRole('button', { name: /List View Controls/i });
|
|
456
|
+
this.MyApplicationsNew_MenuItem = page.getByRole('menuitem', { name: /^New$/i });
|
|
457
|
+
this.MyApplicationsClone_MenuItem = page.getByRole('menuitem', { name: /^Clone$/i });
|
|
458
|
+
this.MyApplicationsRename_MenuItem = page.getByRole('menuitem', { name: /^Rename$/i });
|
|
459
|
+
this.MyApplicationsSharingSettings_MenuItem = page.getByRole('menuitem', { name: /^Sharing Settings$/i });
|
|
460
|
+
this.MyApplicationsSelectFieldsToDisplay_MenuItem = page.getByRole('menuitem', { name: /^Select Fields to Display$/i });
|
|
461
|
+
this.MyApplicationsDelete_MenuItem = page.getByRole('menuitem', { name: /^Delete$/i });
|
|
462
|
+
this.MyApplicationsResetColumnWidths_MenuItem = page.getByRole('menuitem', { name: /^Reset Column Widths$/i });
|
|
463
|
+
this.MyApplicationsRefresh_Btn = page.getByRole('button', { name: /^Refresh$/i });
|
|
464
|
+
this.MyApplicationsCharts_Btn = page.getByRole('button', { name: /^Charts$/i });
|
|
465
|
+
this.MyApplicationsFilters_Btn = page.getByRole('button', { name: /^Filters$/i });
|
|
466
|
+
this.MyApplicationsColumnHeaders_Block = this.MyApplications_Table.locator('thead');
|
|
467
|
+
this.MyApplicationsTableBody_Block = this.MyApplications_Table.locator('tbody');
|
|
468
|
+
this.ApplicationRecordHeader_Text = page.getByText('Application', { exact: true }).first();
|
|
469
|
+
this.ApplicationRecordName_Heading = page.getByRole('heading').filter({ hasText: /Application/i }).first();
|
|
470
|
+
this.ApplicationRecordStatus_Text = page.getByText('Status', { exact: true }).first();
|
|
471
|
+
this.ApplicationRecordApplicationTotalFPL_Text = page.getByText('Application Total FPL', { exact: true });
|
|
472
|
+
this.ApplicationRecordReviewTotalFPL_Text = page.getByText('Review Total FPL', { exact: true });
|
|
473
|
+
this.ApplicationRecordTotalHouseholdMonthlyIncome_Text = page.getByText('Total Household Monthly Income', { exact: true });
|
|
474
|
+
this.ApplicationRecordReviewerTotalHouseholdIncome_Text = page.getByText('Reviewer Total Household Income', { exact: true });
|
|
475
|
+
this.ApplicationRecordPendingWarning_Text = page.getByText(/Pending application: Please complete your application/i);
|
|
476
|
+
this.ApplicationRecordDetailsTab_Btn = page.getByRole('tab', { name: /Details/i });
|
|
477
|
+
this.ApplicationRecordRelatedTab_Btn = page.getByRole('tab', { name: /Related/i });
|
|
478
|
+
this.ApplicationRecordResumeApplication_Btn = page.getByRole('button', { name: /Resume Application/i });
|
|
479
|
+
this.ApplicationRecordScheduleAppointment_Btn = page.getByRole('button', { name: /Schedule Appointment/i });
|
|
480
|
+
this.ApplicationRecordRequestAppeal_Btn = page.getByRole('button', { name: /Request an Appeal/i });
|
|
481
|
+
this.ApplicationRecordSubmitDate_Text = page.getByText('Submit Date', { exact: true });
|
|
482
|
+
this.ApplicationRecordAssignedDate_Text = page.getByText('Assigned Date', { exact: true });
|
|
483
|
+
this.ApplicationRecordOwnerName_Text = page.getByText('Owner Name', { exact: true });
|
|
484
|
+
this.ApplicationRecordEndDate_Text = page.getByText('End Date', { exact: true });
|
|
485
|
+
this.ApplicationRecordHouseholdNumber_Text = page.getByText('Household Number', { exact: true });
|
|
486
|
+
this.ApplicationRecordHouseholdMembers_Text = page.getByText(/Number of Household members/i);
|
|
487
|
+
this.ApplicationRecordSocialServices_Text = page.getByText(/Social Services/i).first();
|
|
488
|
+
this.ApplicationRecordRelatedContent_Block = page.locator('.slds-tabs_default__content.slds-show, .slds-tabs--default__content.slds-show').first();
|
|
489
|
+
this.ApplicationRecordDialog_Block = page.locator('.slds-modal:visible, [role="dialog"]:visible, lightning-flow:visible').first();
|
|
490
|
+
this.ApplicationDetailsTab = page.getByRole('tab', { name: 'Details' });
|
|
491
|
+
//My Medical Coverage Page Locators
|
|
492
|
+
this.MyMedicalCoverageRecords = page.locator('div.slds-card.slds-p-around_medium');
|
|
493
|
+
this.NoEnrollments_Text = page.locator(':text-is("DID NOT FIND ANY ENROLLMENT RECORDS.")')
|
|
494
|
+
this.MyMedicalCoverageBody_Block = page.locator('body');
|
|
495
|
+
this.MyMedicalCoverageBeneficiaryHeader_Text = page.getByText('Beneficiary', { exact: true });
|
|
496
|
+
this.MyMedicalCoverageProgramHeader_Text = page.getByText('Program', { exact: true });
|
|
497
|
+
this.MyMedicalCoverageStatusHeader_Text = page.getByText('Status', { exact: true }).first();
|
|
498
|
+
this.MyMedicalCoverageCoverageBeginDateHeader_Text = page.getByText('Coverage Begin Date', { exact: true });
|
|
499
|
+
this.MyMedicalCoverageCoverageEndDateHeader_Text = page.getByText('Coverage End Date', { exact: true });
|
|
500
|
+
this.MyMedicalCoverageActionsHeader_Text = page.getByText('Actions', { exact: true }).first();
|
|
501
|
+
this.MyMedicalCoverageFirstEnrollmentRow_Block = page.locator('tbody tr').first();
|
|
502
|
+
this.MyMedicalCoverageChangeProvider_Btn = page.getByRole('button', { name: /^Change Provider$/i });
|
|
503
|
+
this.MyMedicalCoverageEnrollmentCard_Btn = page.getByRole('button', { name: /Enrollment card/i });
|
|
504
|
+
this.MyMedicalCoverageUpdateMyInformation_Btn = page.getByRole('button', { name: /^Update My Information$/i });
|
|
505
|
+
this.MyMedicalCoverageBillingInquiries_Btn = page.getByRole('button', { name: /^Billing Inquiries$/i });
|
|
506
|
+
this.MyMedicalCoverageRequestStatusHeading_Text = page.getByText('My Request Status', { exact: true });
|
|
507
|
+
this.MyMedicalCoverageRequestStatus_Block = page.locator('div').filter({ hasText: /My Request Status.*Status.*Effective Date.*Reference/i }).first();
|
|
508
|
+
this.MyMedicalCoverageRequestStatusStatus_Text = page.getByText('Status', { exact: true }).last();
|
|
509
|
+
this.MyMedicalCoverageRequestStatusEffectiveDate_Text = page.getByText('Effective Date', { exact: true });
|
|
510
|
+
this.MyMedicalCoverageRequestStatusReference_Text = page.getByText('Reference', { exact: true });
|
|
511
|
+
this.ChangeProviderDialog_Block = page.locator('section[role="dialog"]:visible, .slds-modal:visible').filter({ hasText: /Change Provider/i }).first();
|
|
512
|
+
this.ChangeProviderHeading_Text = page.getByRole('heading', { name: /^Change Provider$/i });
|
|
513
|
+
this.ChangeProviderInstructions_Text = page.getByText('Select a new primary care provider below.');
|
|
514
|
+
this.ChangeProviderSearch_Input = page.getByPlaceholder('Search...').first();
|
|
515
|
+
this.ChangeProviderReason_dd = page.getByRole('combobox', { name: /Tell us why|Choose Reason/i }).or(page.getByText('Choose Reason', { exact: true }));
|
|
516
|
+
this.ChangeProviderClose_Btn = page.getByRole('button', { name: /^Close$/i }).first();
|
|
517
|
+
this.ChangeProviderSubmit_Btn = page.getByRole('button', { name: /^Submit$/i }).first();
|
|
518
|
+
this.ChangeProviderRequiredFieldErrors_Text = page.getByText('Complete this field.');
|
|
519
|
+
this.ChangeProviderErrorNotification_Text = page.getByText(/Error notification|Complete this field/i);
|
|
520
|
+
this.EnrollmentCardPage_Text = page.getByText('EnrollmentCard', { exact: true });
|
|
521
|
+
this.UpdateMyInformationErrorToast_Text = page.getByText(/Error No application found/i);
|
|
522
|
+
this.ToastClose_Btn = page.getByRole('button', { name: /^Close$/i }).last();
|
|
523
|
+
this.BillingInquiryHeading_Text = page.getByText('Billing Inquiry', { exact: true });
|
|
524
|
+
this.BillingInquiryInstructions_Text = page.getByText(/If you receive a bill that you believe should have been covered/i);
|
|
525
|
+
this.BillingInquiryCoverageReason_Text = page.getByText(/Tell us why you believe these services should be covered/i);
|
|
526
|
+
this.BillingInquiryDateOfService_Input = page.getByRole('textbox', { name: /Date of Service/i }).or(page.getByLabel(/Date of Service/i));
|
|
527
|
+
this.BillingInquiryAmountDue_Input = page.getByRole('textbox', { name: /Amount Due/i }).or(page.getByLabel(/Amount Due/i)).first();
|
|
528
|
+
this.BillingInquiryOtherPayer_dd = page.getByRole('combobox', { name: /Was any portion of this bill/i });
|
|
529
|
+
this.BillingInquiryUploadFiles_Btn = page.getByText('Upload Files', { exact: true }).first();
|
|
530
|
+
this.BillingInquiryUploadDropzone_Text = page.getByText(/Or drop files|At least one document must be uploaded/i);
|
|
531
|
+
this.BillingInquiryApplicationMember_dd = page.getByRole('combobox', { name: /Select Application Member/i });
|
|
532
|
+
this.BillingInquiryAppealReason_dd = page.getByRole('combobox', { name: /Appeal Reason/i });
|
|
533
|
+
this.BillingInquiryProviderFacilityName_Input = page.getByRole('textbox', { name: /Provider or Facility Name/i }).or(page.getByLabel(/Provider or Facility Name/i));
|
|
534
|
+
this.BillingInquiryClaimNumber_Input = page.getByRole('textbox', { name: /Claim/i }).or(page.getByLabel(/Claim/i));
|
|
535
|
+
this.BillingInquiryAmountPaidByOtherProvider_Input = page.getByRole('textbox', { name: /Amount paid by other provider/i }).or(page.getByLabel(/Amount paid by other provider/i));
|
|
536
|
+
this.BillingInquiryDocumentType_dd = page.getByRole('combobox', { name: /Type of document uploaded/i });
|
|
537
|
+
this.BillingInquiryCancel_Btn = page.getByRole('button', { name: /^Cancel$/i });
|
|
538
|
+
this.BillingInquirySubmit_Btn = page.getByRole('button', { name: /^Submit$/i });
|
|
539
|
+
this.BillingInquiryUploadRequiredToast_Text = page.getByText(/Please upload at least one document/i);
|
|
540
|
+
//Resources Page Locators
|
|
541
|
+
this.ResourcesTitle_Text = page.getByRole('heading', { name: 'Resources' });
|
|
542
|
+
this.PolkHealthCarePlanMemberHandbook_Lnk = page.getByRole('link', { name: 'Polk HealthCare Plan Member Handbook (English).pdf' })
|
|
543
|
+
this.UniversalHouseholdAuthorizationForm_Lnk = page.getByRole('link', { name: 'UNIVERSAL HOUSEHOLD AUTHORIZATION FORM_LIMITED_UPDATED 11.18.25.docx' })
|
|
544
|
+
this.UniversalSharedDataInformationSystem_Lnk = page.getByRole('link', { name: 'UNIVERSAL SHARED DATA INFORMATION SYSTEM_Updated 11.18.25.docx' })
|
|
545
|
+
this.EligibilityIncomeVerificationStatement_Lnk = page.getByRole('link', { name: 'Eligibility - Income Verification Statement 031925.pdf' })
|
|
546
|
+
this.ThirdPartySupport_Lnk = page.getByRole('link', { name: 'Third Party Support.pdf' })
|
|
547
|
+
|
|
548
|
+
// Help Page Locators
|
|
549
|
+
this.KnowledgeBaseH1_Text = page.getByRole('heading', { name: 'Knowledge Base', level: 1 });
|
|
550
|
+
this.KnowledgeBaseSubtitle_Text = page.getByText('Find answers to your questions');
|
|
551
|
+
this.KnowledgeBaseSearch_Input = page.getByPlaceholder('Search articles...');
|
|
552
|
+
this.KnowledgeBaseSearchClear_Btn = page.getByRole('button', { name: 'Clear' });
|
|
553
|
+
// Category filters are generic divs (not buttons) in the LWC shadow DOM. Each row contains
|
|
554
|
+
// the category name as a child text node plus a count badge. Clicking the text child propagates
|
|
555
|
+
// the click event to the parent cursor:pointer container.
|
|
556
|
+
// "All" appears twice (Category All and Article Type All). Category All is always first in DOM.
|
|
557
|
+
// Using { exact: true } to avoid strict-mode violations caused by partial substring matches
|
|
558
|
+
// (e.g. "account" in the article summary matching the "Account" category label).
|
|
559
|
+
this.KnowledgeBaseCategoryAll_Lnk = page.locator("//div[@data-name='All']").first();
|
|
560
|
+
this.KnowledgeBaseCategorySupport_Lnk = page.getByText('Support', { exact: true });
|
|
561
|
+
this.KnowledgeBaseCategoryAccount_Lnk = page.getByText('Account', { exact: true });
|
|
562
|
+
this.KnowledgeBaseCategoryGeneral_Lnk = page.getByText('General', { exact: true });
|
|
563
|
+
// Article Type filters are also generic divs (not buttons). "All" for Article Type has exact
|
|
564
|
+
// text "All" (no count appended) — it is the second "All" element in DOM order.
|
|
565
|
+
this.KnowledgeBaseTypeAll_Lnk = page.getByText('All', { exact: true }).nth(1);
|
|
566
|
+
this.KnowledgeBaseTypeFaq_Lnk = page.getByText('FAQ', { exact: true });
|
|
567
|
+
// "Procedure" appears in the Article Type filter sidebar (first) and on article card badges.
|
|
568
|
+
// Using .first() targets the sidebar filter; .nth(1) targets the first card badge.
|
|
569
|
+
this.KnowledgeBaseTypeProcedure_Lnk = page.getByText('Procedure').first();
|
|
570
|
+
// Article cards — each card contains a "Read more →" link; count gives the number of cards.
|
|
571
|
+
this.KnowledgeBaseArticleCards_All = page.getByText('Read more →');
|
|
572
|
+
// Badge on the first article card — second occurrence of "Procedure" after the type filter.
|
|
573
|
+
this.KnowledgeBaseFirstCardBadge_Text = page.getByText('Procedure').nth(1);
|
|
574
|
+
this.KnowledgeBaseFirstCardTitle_Text = page.getByText('How to Reset Your Password').first();
|
|
575
|
+
this.KnowledgeBaseFirstCardSummary_Text = page.getByText('Step-by-step guide to reset your account password quickly and securely').first();
|
|
576
|
+
this.KnowledgeBaseFirstCardDate_Text = page.getByText('4/16/2026, 5:03 AM').first();
|
|
577
|
+
this.KnowledgeBaseFirstCardReadMore_Lnk = page.getByText('Read more →').first();
|
|
578
|
+
this.KnowledgeBaseEmptyState_Text = page.getByText('No articles found. Try a different search or category.');
|
|
579
|
+
this.KnowledgeBaseH1_All = page.locator('h1');
|
|
580
|
+
this.KnowledgeBaseH1Role_Heading = page.getByRole('heading', { level: 1 });
|
|
581
|
+
this.KnowledgeBaseH2_All = page.locator('h2');
|
|
582
|
+
this.KnowledgeBaseH3_All = page.locator('h3');
|
|
583
|
+
this.ArticleDetailH1_Text = page.getByRole('heading', { name: 'How to Reset Your Password', level: 1 });
|
|
584
|
+
// Article detail badge — on the detail page "Procedure" appears only once (the type badge before the H1).
|
|
585
|
+
this.ArticleDetailBadge_Text = page.getByText('Procedure', { exact: true });
|
|
586
|
+
this.ArticleDetailPublished_Text = page.getByText('Published:').first();
|
|
587
|
+
this.ArticleDetailCategory_Text = page.getByText('Category:').first();
|
|
588
|
+
this.ArticleDetailArticleNumber_Text = page.getByText('Article #:').first();
|
|
589
|
+
this.ArticleDetailSummaryLabel_Text = page.getByText('Summary', { exact: true }).first();
|
|
590
|
+
this.ArticleDetailSummaryContent_Text = page.getByText('Step-by-step guide to reset your account password quickly and securely').first();
|
|
591
|
+
this.ArticleDetailAudienceLabel_Text = page.getByText('Audience', { exact: true });
|
|
592
|
+
// Audience and Purpose content span multiple <strong> elements inside a single <p>.
|
|
593
|
+
// Use locator('p').filter() to match the containing paragraph so .textContent() returns the full text.
|
|
594
|
+
this.ArticleDetailAudienceContent_Text = page.locator('p').filter({ hasText: 'This article is intended for all registered customers' });
|
|
595
|
+
this.ArticleDetailPurposeLabel_Text = page.getByText('Purpose', { exact: true });
|
|
596
|
+
this.ArticleDetailPurposeContent_Text = page.locator('p').filter({ hasText: 'The purpose of this procedure is to guide users' });
|
|
597
|
+
// Warning block: all three warning bullets live in a single <p> element.
|
|
598
|
+
// filter({ hasText: bullet }) on this locator returns the paragraph when the bullet is present.
|
|
599
|
+
this.ArticleDetailWarningBlock_Text = page.locator('p').filter({ hasText: '⚠️ Warning' });
|
|
600
|
+
this.ArticleDetailStepsLabel_Text = page.getByText('Steps', { exact: true });
|
|
601
|
+
// Each step is in its own <p> inside the steps container. filter({ hasText: step }) returns
|
|
602
|
+
// the paragraph for that step, letting the test assert visibility per step.
|
|
603
|
+
this.ArticleDetailStepsContent_Block = page.locator('p').filter({ hasText: /^Step \d/ });
|
|
604
|
+
this.ArticleDetailHelpfulLabel_Text = page.getByText('Was this article helpful?');
|
|
605
|
+
this.ArticleDetailHelpfulYes_Btn = page.getByRole('button', { name: /👍.*Yes/ });
|
|
606
|
+
this.ArticleDetailHelpfulNo_Btn = page.getByRole('button', { name: /👎.*No/ });
|
|
607
|
+
this.ArticleDetailBackToKB_Btn = page.getByRole('button', { name: '← Back to Knowledge Base' });
|
|
608
|
+
this.ArticleDetailBanner_Img = page.getByRole('img', { name: 'Polk County Banner' });
|
|
609
|
+
|
|
610
|
+
// Privacy Policy Page Locators
|
|
611
|
+
this.PrivacyPolicyTitle_Text = page.getByRole('heading', { name: 'Polk County Privacy Policy', level: 1 });
|
|
612
|
+
this.RegistrationInformationHeading_Text = page.getByRole('heading', { name: 'Registration Information', level: 2 });
|
|
613
|
+
this.HowPolkCountyUsesYourInformationHeading_Text = page.getByRole('heading', { name: 'How Polk County Uses Your Information', level: 2 });
|
|
614
|
+
this.PrivacyPolicyFirstParagraph_Text = page.getByText('We require some basic information at the time of account creation.');
|
|
615
|
+
this.PrivacyPolicySMSNoticeParagraph_Text = page.getByText('Mobile information will not be shared with third parties or affiliates for marketing or promotional purposes.');
|
|
616
|
+
this.PrivacyPolicySMSNoticeBold_Lbl = page.locator('strong').filter({ hasText: 'SMS Privacy Notice:' });
|
|
617
|
+
this.PrivacyPolicyHowPolkIntroParagraph_Text = page.getByText('We may use your information for the following purposes:');
|
|
618
|
+
this.PrivacyPolicyList_Ul = page.getByRole('heading', { name: 'How Polk County Uses Your Information', level: 2 }).locator('xpath=following::ul[1]');
|
|
619
|
+
this.PrivacyPolicyListItems_Li = page.getByRole('heading', { name: 'How Polk County Uses Your Information', level: 2 }).locator('xpath=following::ul[1]').locator('li');
|
|
620
|
+
this.PrivacyPolicyClosingParagraph_Text = page.getByText('We limit our use of your User Personal Information to the purposes listed in this Privacy Policy.');
|
|
621
|
+
this.PrivacyPolicyH1_All = page.locator('h1');
|
|
622
|
+
this.PrivacyPolicyH1Role_Heading = page.getByRole('heading', { level: 1 });
|
|
623
|
+
this.PrivacyPolicyH2_All = page.locator('h2');
|
|
624
|
+
this.PrivacyPolicyH3_All = page.locator('h3');
|
|
625
|
+
this.HtmlRoot_Elem = page.locator('html');
|
|
626
|
+
|
|
627
|
+
}
|
|
628
|
+
|
|
629
|
+
async gotoURL(url: string, options?: { handleConsentUpdate?: boolean }): Promise<void> {
|
|
630
|
+
await this.page.goto(url);
|
|
631
|
+
if (options?.handleConsentUpdate !== false) {
|
|
632
|
+
await this.completeConsentFormUpdateIfRequired();
|
|
633
|
+
}
|
|
634
|
+
}
|
|
635
|
+
|
|
636
|
+
async clickLoginButton(): Promise<void> {
|
|
637
|
+
await this.Login_Btn.click();
|
|
638
|
+
await this.UsernameField_Lbl.waitFor({ state: 'attached' });
|
|
639
|
+
}
|
|
640
|
+
|
|
641
|
+
async clickLoginSubmitButton(): Promise<void> {
|
|
642
|
+
await this.LoginSubmit_Btn.click();
|
|
643
|
+
}
|
|
644
|
+
|
|
645
|
+
async clickForgotPasswordLink(): Promise<void> {
|
|
646
|
+
await this.ForgotPassword_Lnk.click();
|
|
647
|
+
}
|
|
648
|
+
|
|
649
|
+
async clickSignUpLink(): Promise<void> {
|
|
650
|
+
await this.SignUp_Lnk.click();
|
|
651
|
+
}
|
|
652
|
+
|
|
653
|
+
async clickSendResetLinkButton(): Promise<void> {
|
|
654
|
+
await this.SendResetLink_Btn.click();
|
|
655
|
+
}
|
|
656
|
+
|
|
657
|
+
async clickSuffixField(): Promise<void> {
|
|
658
|
+
await this.SuffixField_dd.click();
|
|
659
|
+
}
|
|
660
|
+
|
|
661
|
+
async clickDOBField(): Promise<void> {
|
|
662
|
+
await this.DOBField_Input.click();
|
|
663
|
+
}
|
|
664
|
+
|
|
665
|
+
async clickPhysicalAddressCountryField(): Promise<void> {
|
|
666
|
+
await this.PhysicalAddress_CountryField_dd.click();
|
|
667
|
+
}
|
|
668
|
+
|
|
669
|
+
async clickPhysicalAddressStateField(): Promise<void> {
|
|
670
|
+
await this.PhysicalAddress_StateField_dd.click();
|
|
671
|
+
}
|
|
672
|
+
|
|
673
|
+
async clickMailingAddressCountryField(): Promise<void> {
|
|
674
|
+
await this.MailingAddress_CountryField_dd.click();
|
|
675
|
+
}
|
|
676
|
+
|
|
677
|
+
async clickMailingAddressStateField(): Promise<void> {
|
|
678
|
+
await this.MailingAddress_StateField_dd.click();
|
|
679
|
+
}
|
|
680
|
+
|
|
681
|
+
async clickRegisterButton(): Promise<void> {
|
|
682
|
+
await this.Register_Btn.click();
|
|
683
|
+
}
|
|
684
|
+
|
|
685
|
+
async clickPhysicalAddressAddressField(): Promise<void> {
|
|
686
|
+
await this.PhysicalAddress_AddressField.click();
|
|
687
|
+
}
|
|
688
|
+
|
|
689
|
+
async clickMailingAddressAddressField(): Promise<void> {
|
|
690
|
+
await this.MailingAddress_AddressField.click();
|
|
691
|
+
}
|
|
692
|
+
|
|
693
|
+
async clickSameAsPhysicalToggle(): Promise<void> {
|
|
694
|
+
await this.MailingAddress_SameAsPhysical_Toggle.click();
|
|
695
|
+
}
|
|
696
|
+
|
|
697
|
+
async clickCreateApplicationLink(): Promise<void> {
|
|
698
|
+
await this.CreateApplication_Lnk.click();
|
|
699
|
+
}
|
|
700
|
+
|
|
701
|
+
async clickMyApplicationLink(): Promise<void> {
|
|
702
|
+
await this.MyApplication_Lnk.click();
|
|
703
|
+
}
|
|
704
|
+
|
|
705
|
+
async gotoMyApplicationsPage(): Promise<void> {
|
|
706
|
+
await this.gotoURL('/polkphpapplicant/s/careprogram/CareProgram/Default');
|
|
707
|
+
await this.waitForMyApplicationsPageReady();
|
|
708
|
+
}
|
|
709
|
+
|
|
710
|
+
async waitForMyApplicationsPageReady(): Promise<void> {
|
|
711
|
+
await this.Logout_Btn.waitFor({ state: 'visible' });
|
|
712
|
+
await this.MyApplicationsHeading_Text.waitFor({ state: 'visible' });
|
|
713
|
+
await this.MyApplications_Table.waitFor({ state: 'visible' });
|
|
714
|
+
}
|
|
715
|
+
|
|
716
|
+
async waitForMyApplicationsListToSettle(): Promise<void> {
|
|
717
|
+
await this.page.waitForLoadState('networkidle', { timeout: 15_000 }).catch(() => {});
|
|
718
|
+
await this.MyApplications_Table.waitFor({ state: 'visible' });
|
|
719
|
+
}
|
|
720
|
+
|
|
721
|
+
async searchMyApplicationsList(searchText: string): Promise<void> {
|
|
722
|
+
await this.MyApplicationsSearch_Input.fill(searchText);
|
|
723
|
+
await this.MyApplicationsSearch_Input.press('Enter');
|
|
724
|
+
await this.waitForMyApplicationsListToSettle();
|
|
725
|
+
}
|
|
726
|
+
|
|
727
|
+
async clearMyApplicationsSearch(): Promise<void> {
|
|
728
|
+
await this.MyApplicationsClearSearch_Btn.click();
|
|
729
|
+
await this.waitForMyApplicationsListToSettle();
|
|
730
|
+
}
|
|
731
|
+
|
|
732
|
+
async clickMyApplicationsNameSort(): Promise<void> {
|
|
733
|
+
await this.MyApplicationsNameColumnHeader_Btn.click();
|
|
734
|
+
await this.waitForMyApplicationsListToSettle();
|
|
735
|
+
}
|
|
736
|
+
|
|
737
|
+
async clickMyApplicationsLastModifiedDateSort(): Promise<void> {
|
|
738
|
+
await this.MyApplicationsLastModifiedDateColumnHeader_Btn.click();
|
|
739
|
+
await this.waitForMyApplicationsListToSettle();
|
|
740
|
+
}
|
|
741
|
+
|
|
742
|
+
async openMyApplicationsLastModifiedDateColumnActions(): Promise<void> {
|
|
743
|
+
await this.MyApplicationsLastModifiedDateColumnActions_Btn.click();
|
|
744
|
+
await this.MyApplicationsWrapText_MenuItem.waitFor({ state: 'visible' });
|
|
745
|
+
}
|
|
746
|
+
|
|
747
|
+
async openFirstMyApplicationsRowActions(): Promise<void> {
|
|
748
|
+
await this.MyApplicationsFirstRowActions_Btn.click();
|
|
749
|
+
await this.MyApplicationsEdit_MenuItem.waitFor({ state: 'visible' });
|
|
750
|
+
}
|
|
751
|
+
|
|
752
|
+
async openFirstMyApplicationsRecord(): Promise<string> {
|
|
753
|
+
const applicationName = ((await this.MyApplicationsFirstApplication_Lnk.textContent()) ?? '').trim();
|
|
754
|
+
await this.MyApplicationsFirstApplication_Lnk.click();
|
|
755
|
+
await this.page.waitForURL(/\/polkphpapplicant\/s\/careprogram\/[^/]+\/[^/?#]+/i, { timeout: 45_000 });
|
|
756
|
+
await this.page.waitForLoadState('networkidle', { timeout: 15_000 }).catch(() => {});
|
|
757
|
+
return applicationName;
|
|
758
|
+
}
|
|
759
|
+
|
|
760
|
+
async openMyApplicationsListViewSelector(): Promise<void> {
|
|
761
|
+
await this.MyApplicationsListViewSelector_Btn.click();
|
|
762
|
+
await this.MyApplicationsRecentlyViewed_MenuItem.waitFor({ state: 'visible' });
|
|
763
|
+
}
|
|
764
|
+
|
|
765
|
+
async selectMyApplicationsListView(listView: 'All Applications' | 'Appealed Applications' | 'Recently Viewed' | 'With Priority Indicator'): Promise<void> {
|
|
766
|
+
await this.openMyApplicationsListViewSelector();
|
|
767
|
+
const listViewLocator = {
|
|
768
|
+
'All Applications': this.MyApplicationsAllApplications_MenuItem,
|
|
769
|
+
'Appealed Applications': this.MyApplicationsAppealedApplications_MenuItem,
|
|
770
|
+
'Recently Viewed': this.MyApplicationsRecentlyViewed_MenuItem,
|
|
771
|
+
'With Priority Indicator': this.MyApplicationsWithPriorityIndicator_MenuItem,
|
|
772
|
+
}[listView];
|
|
773
|
+
await listViewLocator.click();
|
|
774
|
+
await this.waitForMyApplicationsListToSettle();
|
|
775
|
+
}
|
|
776
|
+
|
|
777
|
+
async openMyApplicationsListViewControls(): Promise<void> {
|
|
778
|
+
await this.MyApplicationsListViewControls_Btn.click();
|
|
779
|
+
await this.MyApplicationsResetColumnWidths_MenuItem.waitFor({ state: 'visible' });
|
|
780
|
+
}
|
|
781
|
+
|
|
782
|
+
async refreshMyApplicationsList(): Promise<void> {
|
|
783
|
+
await this.MyApplicationsRefresh_Btn.click();
|
|
784
|
+
await this.waitForMyApplicationsListToSettle();
|
|
785
|
+
}
|
|
786
|
+
|
|
787
|
+
async getMyApplicationsVisibleRowCount(): Promise<number> {
|
|
788
|
+
return this.MyApplicationsRows_All.count();
|
|
789
|
+
}
|
|
790
|
+
|
|
791
|
+
async getMyApplicationsFirstRowText(): Promise<string> {
|
|
792
|
+
return ((await this.MyApplicationsFirstRow_Block.textContent()) ?? '').replace(/\s+/g, ' ').trim();
|
|
793
|
+
}
|
|
794
|
+
|
|
795
|
+
async getMyApplicationsRowsText(): Promise<string[]> {
|
|
796
|
+
return this.MyApplicationsRows_All.evaluateAll((rows) =>
|
|
797
|
+
rows.map((row) => (row.textContent ?? '').replace(/\s+/g, ' ').trim()).filter(Boolean),
|
|
798
|
+
);
|
|
799
|
+
}
|
|
800
|
+
|
|
801
|
+
async getMyApplicationsVisibleLastModifiedDateTexts(limit = 5): Promise<string[]> {
|
|
802
|
+
const rows = await this.getMyApplicationsRowsText();
|
|
803
|
+
const datePattern = /\d{1,2}\/\d{1,2}\/\d{4},?\s+\d{1,2}:\d{2}\s*(?:AM|PM)?/i;
|
|
804
|
+
return rows
|
|
805
|
+
.map((rowText) => rowText.match(datePattern)?.[0] ?? '')
|
|
806
|
+
.filter(Boolean)
|
|
807
|
+
.slice(0, limit);
|
|
808
|
+
}
|
|
809
|
+
|
|
810
|
+
async getMyApplicationsListSummaryText(): Promise<string> {
|
|
811
|
+
return ((await this.MyApplicationsListSummary_Text.textContent()) ?? '').replace(/\s+/g, ' ').trim();
|
|
812
|
+
}
|
|
813
|
+
|
|
814
|
+
async getMyApplicationsSortStateText(): Promise<string> {
|
|
815
|
+
const ariaSort = await this.MyApplicationsLastModifiedDateColumnHeader_Btn
|
|
816
|
+
.locator('xpath=ancestor::*[@aria-sort][1]')
|
|
817
|
+
.getAttribute('aria-sort')
|
|
818
|
+
.catch(() => null);
|
|
819
|
+
const headerText = ((await this.MyApplicationsColumnHeaders_Block.textContent()) ?? '').replace(/\s+/g, ' ').trim();
|
|
820
|
+
return [ariaSort, headerText].filter(Boolean).join(' ');
|
|
821
|
+
}
|
|
822
|
+
|
|
823
|
+
async cancelOrCloseOpenDialog(): Promise<void> {
|
|
824
|
+
const closeButton = this.page.getByRole('button', { name: /Cancel|Close|Close this window/i }).first();
|
|
825
|
+
if (await closeButton.isVisible().catch(() => false)) {
|
|
826
|
+
await closeButton.click();
|
|
827
|
+
} else {
|
|
828
|
+
await this.page.keyboard.press('Escape');
|
|
829
|
+
}
|
|
830
|
+
await this.page.waitForTimeout(500);
|
|
831
|
+
}
|
|
832
|
+
|
|
833
|
+
async clickLogoutButton(): Promise<void> {
|
|
834
|
+
await this.Logout_Btn.click();
|
|
835
|
+
}
|
|
836
|
+
|
|
837
|
+
async loginAsApplicant(username: string, password: string): Promise<void> {
|
|
838
|
+
await this.UsernameField_Input.fill(username);
|
|
839
|
+
await this.PasswordField_Input.fill(password);
|
|
840
|
+
await this.LoginSubmit_Btn.click();
|
|
841
|
+
await this.completeConsentFormUpdateIfRequired();
|
|
842
|
+
}
|
|
843
|
+
|
|
844
|
+
async getChartsUnavailableTitle(): Promise<string | null> {
|
|
845
|
+
return this.MyApplicationsCharts_Btn.getAttribute('title');
|
|
846
|
+
}
|
|
847
|
+
|
|
848
|
+
async getFiltersUnavailableTitle(): Promise<string | null> {
|
|
849
|
+
return this.MyApplicationsFilters_Btn.getAttribute('title');
|
|
850
|
+
}
|
|
851
|
+
|
|
852
|
+
async selectApplicationRecordDetailsTab(): Promise<void> {
|
|
853
|
+
await this.ApplicationRecordDetailsTab_Btn.click();
|
|
854
|
+
}
|
|
855
|
+
|
|
856
|
+
async selectApplicationRecordRelatedTab(): Promise<void> {
|
|
857
|
+
await this.ApplicationRecordRelatedTab_Btn.click();
|
|
858
|
+
await this.page.waitForLoadState('networkidle', { timeout: 15_000 }).catch(() => {});
|
|
859
|
+
}
|
|
860
|
+
|
|
861
|
+
async clickResumeApplicationButton(): Promise<void> {
|
|
862
|
+
await this.ApplicationRecordResumeApplication_Btn.click();
|
|
863
|
+
await this.page.waitForLoadState('networkidle', { timeout: 15_000 }).catch(() => {});
|
|
864
|
+
}
|
|
865
|
+
|
|
866
|
+
async clickScheduleAppointmentButton(): Promise<void> {
|
|
867
|
+
await this.ApplicationRecordScheduleAppointment_Btn.click();
|
|
868
|
+
}
|
|
869
|
+
|
|
870
|
+
async clickRequestAppealButton(): Promise<void> {
|
|
871
|
+
await this.ApplicationRecordRequestAppeal_Btn.click();
|
|
872
|
+
}
|
|
873
|
+
|
|
874
|
+
async navigateToUnauthorizedApplicationRecord(recordPath: string): Promise<void> {
|
|
875
|
+
await this.gotoURL(recordPath, { handleConsentUpdate: false });
|
|
876
|
+
await this.page.waitForLoadState('networkidle', { timeout: 15_000 }).catch(() => {});
|
|
877
|
+
}
|
|
878
|
+
async clickMyMedicalCoverageLink(): Promise<void> {
|
|
879
|
+
await this.MyMedicalCoverage_Lnk.click();
|
|
880
|
+
}
|
|
881
|
+
|
|
882
|
+
async gotoMyMedicalCoveragePage(): Promise<void> {
|
|
883
|
+
await this.gotoURL('/polkphpapplicant/s/enrollments?language=en_US');
|
|
884
|
+
await this.waitForMyMedicalCoveragePageReady();
|
|
885
|
+
}
|
|
886
|
+
|
|
887
|
+
async waitForMyMedicalCoveragePageReady(): Promise<void> {
|
|
888
|
+
await this.Logout_Btn.waitFor({ state: 'visible' });
|
|
889
|
+
await this.MyMedicalCoverageBody_Block.waitFor({ state: 'visible' });
|
|
890
|
+
}
|
|
891
|
+
|
|
892
|
+
async hasMedicalCoverageRecords(): Promise<boolean> {
|
|
893
|
+
return this.MyMedicalCoverageChangeProvider_Btn
|
|
894
|
+
.or(this.MyMedicalCoverageEnrollmentCard_Btn)
|
|
895
|
+
.first()
|
|
896
|
+
.isVisible({ timeout: 5_000 })
|
|
897
|
+
.catch(() => false);
|
|
898
|
+
}
|
|
899
|
+
|
|
900
|
+
async getMyMedicalCoveragePageText(): Promise<string> {
|
|
901
|
+
return this.MyMedicalCoverageBody_Block.evaluate((body) => ((body as HTMLElement).innerText ?? '').replace(/\s+/g, ' ').trim());
|
|
902
|
+
}
|
|
903
|
+
|
|
904
|
+
async getFirstEnrollmentRowText(): Promise<string> {
|
|
905
|
+
return this.MyMedicalCoverageFirstEnrollmentRow_Block.evaluate((row) => ((row as HTMLElement).innerText ?? '').replace(/\s+/g, ' ').trim());
|
|
906
|
+
}
|
|
907
|
+
|
|
908
|
+
async clickChangeProviderButton(): Promise<void> {
|
|
909
|
+
await this.MyMedicalCoverageChangeProvider_Btn.click();
|
|
910
|
+
await this.ChangeProviderDialog_Block.waitFor({ state: 'visible' });
|
|
911
|
+
}
|
|
912
|
+
|
|
913
|
+
async submitChangeProviderRequest(): Promise<void> {
|
|
914
|
+
await this.ChangeProviderSubmit_Btn.click();
|
|
915
|
+
}
|
|
916
|
+
|
|
917
|
+
async closeChangeProviderDialog(): Promise<void> {
|
|
918
|
+
await this.ChangeProviderClose_Btn.click();
|
|
919
|
+
await this.ChangeProviderDialog_Block.waitFor({ state: 'hidden', timeout: 10_000 }).catch(() => {});
|
|
920
|
+
}
|
|
921
|
+
|
|
922
|
+
async clickEnrollmentCardButton(): Promise<void> {
|
|
923
|
+
await this.MyMedicalCoverageEnrollmentCard_Btn.click();
|
|
924
|
+
await this.page.waitForURL(/\/polkphpapplicant\/s\/enrollmentcard/i, { timeout: 30_000 }).catch(() => {});
|
|
925
|
+
}
|
|
926
|
+
|
|
927
|
+
async clickUpdateMyInformationButton(): Promise<void> {
|
|
928
|
+
await this.MyMedicalCoverageUpdateMyInformation_Btn.click();
|
|
929
|
+
await this.UpdateMyInformationErrorToast_Text.waitFor({ state: 'visible', timeout: 15_000 }).catch(() => {});
|
|
930
|
+
}
|
|
931
|
+
|
|
932
|
+
async clickBillingInquiriesButton(): Promise<void> {
|
|
933
|
+
await this.MyMedicalCoverageBillingInquiries_Btn.click();
|
|
934
|
+
await this.page.waitForURL(/\/polkphpapplicant\/s\/billing-inquiries/i, { timeout: 30_000 });
|
|
935
|
+
await this.BillingInquiryHeading_Text.waitFor({ state: 'visible' });
|
|
936
|
+
}
|
|
937
|
+
|
|
938
|
+
async submitBillingInquiry(): Promise<void> {
|
|
939
|
+
await this.BillingInquirySubmit_Btn.click();
|
|
940
|
+
}
|
|
941
|
+
|
|
942
|
+
async cancelBillingInquiry(): Promise<void> {
|
|
943
|
+
await this.BillingInquiryCancel_Btn.click();
|
|
944
|
+
await this.MyMedicalCoverageBody_Block.waitFor({ state: 'visible' });
|
|
945
|
+
}
|
|
946
|
+
|
|
947
|
+
async dismissToastIfVisible(): Promise<void> {
|
|
948
|
+
if (await this.ToastClose_Btn.isVisible({ timeout: 3_000 }).catch(() => false)) {
|
|
949
|
+
await this.ToastClose_Btn.click();
|
|
950
|
+
}
|
|
951
|
+
}
|
|
952
|
+
|
|
953
|
+
async clickResourcesLink(): Promise<void> {
|
|
954
|
+
await this.Resources_Lnk.click();
|
|
955
|
+
}
|
|
956
|
+
|
|
957
|
+
async clickPrivacyPolicyHeaderLink(): Promise<void> {
|
|
958
|
+
await this.PrivacyPolicyHeader_Lnk.click();
|
|
959
|
+
}
|
|
960
|
+
|
|
961
|
+
async clickHomeLink(): Promise<void> {
|
|
962
|
+
await this.Home_Lnk.click();
|
|
963
|
+
}
|
|
964
|
+
|
|
965
|
+
// Help Page Click Helpers
|
|
966
|
+
async clickHelpHeaderLink(): Promise<void> {
|
|
967
|
+
await this.Help_Lnk.click();
|
|
968
|
+
}
|
|
969
|
+
|
|
970
|
+
async clickAllCategoryFilter(): Promise<void> {
|
|
971
|
+
await this.KnowledgeBaseCategoryAll_Lnk.click();
|
|
972
|
+
}
|
|
973
|
+
|
|
974
|
+
async clickAccountCategoryFilter(): Promise<void> {
|
|
975
|
+
await this.KnowledgeBaseCategoryAccount_Lnk.click();
|
|
976
|
+
}
|
|
977
|
+
|
|
978
|
+
async clickSupportCategoryFilter(): Promise<void> {
|
|
979
|
+
await this.KnowledgeBaseCategorySupport_Lnk.click();
|
|
980
|
+
}
|
|
981
|
+
|
|
982
|
+
async clickGeneralCategoryFilter(): Promise<void> {
|
|
983
|
+
await this.KnowledgeBaseCategoryGeneral_Lnk.click();
|
|
984
|
+
}
|
|
985
|
+
|
|
986
|
+
async clickAllArticleTypeFilter(): Promise<void> {
|
|
987
|
+
await this.KnowledgeBaseTypeAll_Lnk.click();
|
|
988
|
+
}
|
|
989
|
+
|
|
990
|
+
async clickFaqArticleTypeFilter(): Promise<void> {
|
|
991
|
+
await this.KnowledgeBaseTypeFaq_Lnk.click();
|
|
992
|
+
}
|
|
993
|
+
|
|
994
|
+
async clickProcedureArticleTypeFilter(): Promise<void> {
|
|
995
|
+
await this.KnowledgeBaseTypeProcedure_Lnk.click();
|
|
996
|
+
}
|
|
997
|
+
|
|
998
|
+
async clickHowToResetPasswordCard(): Promise<void> {
|
|
999
|
+
await this.KnowledgeBaseFirstCardTitle_Text.click();
|
|
1000
|
+
}
|
|
1001
|
+
|
|
1002
|
+
async clickBackToKnowledgeBase(): Promise<void> {
|
|
1003
|
+
await this.ArticleDetailBackToKB_Btn.click();
|
|
1004
|
+
}
|
|
1005
|
+
|
|
1006
|
+
async clickHelpfulYesButton(): Promise<void> {
|
|
1007
|
+
await this.ArticleDetailHelpfulYes_Btn.click();
|
|
1008
|
+
}
|
|
1009
|
+
|
|
1010
|
+
async clickHelpfulNoButton(): Promise<void> {
|
|
1011
|
+
await this.ArticleDetailHelpfulNo_Btn.click();
|
|
1012
|
+
}
|
|
1013
|
+
|
|
1014
|
+
async clickSearchClearButton(): Promise<void> {
|
|
1015
|
+
await this.KnowledgeBaseSearchClear_Btn.click();
|
|
1016
|
+
}
|
|
1017
|
+
|
|
1018
|
+
async getHelpfulYesCount(): Promise<number> {
|
|
1019
|
+
const text = (await this.ArticleDetailHelpfulYes_Btn.textContent()) ?? '';
|
|
1020
|
+
const match = text.match(/\((\d+)\)/);
|
|
1021
|
+
return match ? parseInt(match[1], 10) : 0;
|
|
1022
|
+
}
|
|
1023
|
+
|
|
1024
|
+
async getHelpfulNoCount(): Promise<number> {
|
|
1025
|
+
const text = (await this.ArticleDetailHelpfulNo_Btn.textContent()) ?? '';
|
|
1026
|
+
const match = text.match(/\((\d+)\)/);
|
|
1027
|
+
return match ? parseInt(match[1], 10) : 0;
|
|
1028
|
+
}
|
|
1029
|
+
|
|
1030
|
+
async getFilterCount(locator: Locator): Promise<number> {
|
|
1031
|
+
const text = ((await locator.textContent()) ?? '').trim();
|
|
1032
|
+
const n = parseInt(text, 10);
|
|
1033
|
+
return Number.isNaN(n) ? 0 : n;
|
|
1034
|
+
}
|
|
1035
|
+
|
|
1036
|
+
async fillMandatoryFields(firstName: string, lastName: string, email: string, physicalAddress: string, mailingAddress: string): Promise<void> {
|
|
1037
|
+
await this.FirstNameField_Input.fill(firstName);
|
|
1038
|
+
await this.LastNameField_Input.fill(lastName);
|
|
1039
|
+
await this.EmailField_Input.fill(email);
|
|
1040
|
+
//Need check this logic
|
|
1041
|
+
if(mailingAddress)
|
|
1042
|
+
{
|
|
1043
|
+
await this.Agreement_Text.scrollIntoViewIfNeeded();
|
|
1044
|
+
await this.MailingAddress_AddressField.fill(mailingAddress);
|
|
1045
|
+
await this.clickMailingAddressAddressField();
|
|
1046
|
+
await (this.page.locator('div.slds-align_absolute-center').last()).waitFor({ state: 'visible' });
|
|
1047
|
+
await this.MailingAddress_Response_ddl.first().click();
|
|
1048
|
+
}
|
|
1049
|
+
else
|
|
1050
|
+
{
|
|
1051
|
+
await this.MailingAddress_AddressField.fill('');
|
|
1052
|
+
}
|
|
1053
|
+
if(physicalAddress)
|
|
1054
|
+
{
|
|
1055
|
+
await this.PhysicalAddress_AddressField.fill(physicalAddress);
|
|
1056
|
+
await this.clickPhysicalAddressAddressField();
|
|
1057
|
+
await (this.PhysicalAddress_Response_ddl.first()).waitFor({ state: 'visible' });
|
|
1058
|
+
await this.PhysicalAddress_Response_ddl.first().click();
|
|
1059
|
+
}
|
|
1060
|
+
else
|
|
1061
|
+
{
|
|
1062
|
+
await this.PhysicalAddress_AddressField.fill('');
|
|
1063
|
+
}
|
|
1064
|
+
|
|
1065
|
+
|
|
1066
|
+
|
|
1067
|
+
}
|
|
1068
|
+
|
|
1069
|
+
async getTomorrowDateWithFormat(){
|
|
1070
|
+
const date = new Date();
|
|
1071
|
+
date.setDate(date.getDate() + 1);
|
|
1072
|
+
|
|
1073
|
+
const formattedDate = date.toLocaleDateString('en-US', {
|
|
1074
|
+
month: 'short',
|
|
1075
|
+
day: 'numeric',
|
|
1076
|
+
year: 'numeric'
|
|
1077
|
+
});
|
|
1078
|
+
|
|
1079
|
+
return formattedDate;
|
|
1080
|
+
}
|
|
1081
|
+
|
|
1082
|
+
async getCurrentDate(){
|
|
1083
|
+
const today = new Date();
|
|
1084
|
+
const formattedDate = new Intl.DateTimeFormat('en-GB', {
|
|
1085
|
+
day: '2-digit',
|
|
1086
|
+
month: '2-digit',
|
|
1087
|
+
year: '2-digit',
|
|
1088
|
+
})
|
|
1089
|
+
.format(today)
|
|
1090
|
+
.replace(/\//g, ''); // Removes the slashes to get DDMMYY
|
|
1091
|
+
return formattedDate;
|
|
1092
|
+
}
|
|
1093
|
+
|
|
1094
|
+
async generateRandomNumber(){
|
|
1095
|
+
const randomThreeDigits = Math.floor(Math.random() * 1000).toString().padStart(3, '0');
|
|
1096
|
+
return randomThreeDigits;
|
|
1097
|
+
}
|
|
1098
|
+
|
|
1099
|
+
async generateRandomText(maxLength: number = 3){
|
|
1100
|
+
const letters = 'abcdefghijklmnopqrstuvwxyz';
|
|
1101
|
+
const length = Math.floor(Math.random() * maxLength) + 1;
|
|
1102
|
+
let randomText = '';
|
|
1103
|
+
for (let i = 0; i < length; i++) {
|
|
1104
|
+
randomText += letters[Math.floor(Math.random() * letters.length)];
|
|
1105
|
+
}
|
|
1106
|
+
return randomText;
|
|
1107
|
+
}
|
|
1108
|
+
|
|
1109
|
+
async isConsentFormUpdateRequiredVisible(timeout = 8_000): Promise<boolean> {
|
|
1110
|
+
return this.ConsentFormUpdateRequired_Heading.waitFor({ state: 'visible', timeout })
|
|
1111
|
+
.then(() => true)
|
|
1112
|
+
.catch(() => false);
|
|
1113
|
+
}
|
|
1114
|
+
|
|
1115
|
+
async isPortalConsentFormVisible(timeout = 10_000): Promise<boolean> {
|
|
1116
|
+
if (/\/consent/i.test(this.page.url())) {
|
|
1117
|
+
return true;
|
|
1118
|
+
}
|
|
1119
|
+
return this.PortalConsentInformation_ChkBox.waitFor({ state: 'visible', timeout })
|
|
1120
|
+
.then(() => true)
|
|
1121
|
+
.catch(() => false);
|
|
1122
|
+
}
|
|
1123
|
+
|
|
1124
|
+
async clickReSignConsentFormButton(): Promise<void> {
|
|
1125
|
+
await this.ReSignConsentForm_Button.click();
|
|
1126
|
+
await this.page.waitForURL(/\/consent/i, { timeout: 45_000 });
|
|
1127
|
+
}
|
|
1128
|
+
|
|
1129
|
+
async signPortalConsentForm(): Promise<void> {
|
|
1130
|
+
const signatureBox = await this.PortalConsentSignature_Canvas.boundingBox();
|
|
1131
|
+
if (!signatureBox) {
|
|
1132
|
+
throw new Error('Portal consent signature canvas is not visible');
|
|
1133
|
+
}
|
|
1134
|
+
await this.page.mouse.move(signatureBox.x + 20, signatureBox.y + signatureBox.height / 2);
|
|
1135
|
+
await this.page.mouse.down();
|
|
1136
|
+
await this.page.mouse.move(signatureBox.x + 80, signatureBox.y + 20);
|
|
1137
|
+
await this.page.mouse.move(signatureBox.x + 140, signatureBox.y + signatureBox.height - 20);
|
|
1138
|
+
await this.page.mouse.up();
|
|
1139
|
+
}
|
|
1140
|
+
|
|
1141
|
+
async fillPortalConsentForm(): Promise<void> {
|
|
1142
|
+
await this.PortalConsentInformation_ChkBox.click();
|
|
1143
|
+
await this.signPortalConsentForm();
|
|
1144
|
+
await this.PortalAcceptSignature_Button.click();
|
|
1145
|
+
await this.PortalAgreeAndConsent_Button.click();
|
|
1146
|
+
}
|
|
1147
|
+
|
|
1148
|
+
/**
|
|
1149
|
+
* After login or portal navigation: dismiss "Consent Form Update Required" and re-sign if shown.
|
|
1150
|
+
* No-op when the gate is not present.
|
|
1151
|
+
*/
|
|
1152
|
+
async completeConsentFormUpdateIfRequired(): Promise<void> {
|
|
1153
|
+
const needsResign = await this.isConsentFormUpdateRequiredVisible();
|
|
1154
|
+
|
|
1155
|
+
if (needsResign) {
|
|
1156
|
+
await this.clickReSignConsentFormButton();
|
|
1157
|
+
} else if (!/\/consent/i.test(this.page.url())) {
|
|
1158
|
+
return;
|
|
1159
|
+
}
|
|
1160
|
+
|
|
1161
|
+
if (await this.isPortalConsentFormVisible()) {
|
|
1162
|
+
await this.fillPortalConsentForm();
|
|
1163
|
+
}
|
|
1164
|
+
|
|
1165
|
+
if (needsResign) {
|
|
1166
|
+
await this.ReSignConsentForm_Button.waitFor({ state: 'hidden', timeout: 45_000 }).catch(() => {});
|
|
1167
|
+
await this.WelcomeHeading_Text.waitFor({ state: 'visible', timeout: 45_000 }).catch(() => {});
|
|
1168
|
+
}
|
|
1169
|
+
}
|
|
1170
|
+
|
|
1171
|
+
}
|