File tree Expand file tree Collapse file tree 1 file changed +10
-3
lines changed
playwright-e2e/dsm/pages/kitUpload-page Expand file tree Collapse file tree 1 file changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -20,9 +20,12 @@ export default class KitUploadPage {
2020
2121 public async waitForReady ( kitTypes ?: KitTypeEnum [ ] ) : Promise < void > {
2222 const knownKitTypes = kitTypes ?? this . expectedKitTypes ; //Use the param kit types if provided, if they are not, then use the general expected kit types
23- await this . page . waitForLoadState ( 'networkidle' ) ;
23+ await Promise . all ( [
24+ this . page . waitForLoadState ( ) ,
25+ this . assertPageTitle ( )
26+ ] ) ;
27+ await expect ( this . skipAddressValidationCheckbox ) . toBeVisible ( ) ;
2428 await waitForNoSpinner ( this . page ) ;
25- await this . assertPageTitle ( ) ;
2629 await this . assertDisplayedKitTypes ( knownKitTypes ) ;
2730 }
2831
@@ -142,7 +145,11 @@ export default class KitUploadPage {
142145 }
143146
144147 public async skipAddressValidation ( value = false ) : Promise < void > {
145- value && await this . page . locator ( '//mat-checkbox[.//*[@class="mat-checkbox-label" and text()="Skip address validation on upload"]]' ) . click ( ) ;
148+ value && await this . skipAddressValidationCheckbox . click ( ) ;
149+ }
150+
151+ public get skipAddressValidationCheckbox ( ) : Locator {
152+ return this . page . locator ( '//mat-checkbox[.//*[@class="mat-checkbox-label" and text()="Skip address validation on upload"]]' ) ;
146153 }
147154
148155 /* XPaths */
You can’t perform that action at this time.
0 commit comments