Change flow to select no for sms opt in
This commit is contained in:
parent
d1d924c4f3
commit
bb56843114
1 changed files with 6 additions and 6 deletions
|
|
@ -35,7 +35,7 @@ export class PaymentMethodPage extends BasePage {
|
|||
this.payAtAppointmentButton = this.page.locator('[buttonlabel="Pay at my appointment"]');
|
||||
|
||||
this.textReminderYesButton = this.page.locator('div.button-content', { hasText: /^yes$/i });
|
||||
this.textReminderNoButton = this.page.locator('div.button-content', { hasText: 'No' });
|
||||
this.textReminderNoButton = this.page.locator('div.button-content', { hasText: /^no$/i });
|
||||
this.continueToCheckoutButton = this.page.getByRole('button', { name: 'Continue to checkout' });
|
||||
this.submitButton = this.page.getByRole('button', { name: 'Submit' });
|
||||
}
|
||||
|
|
@ -46,20 +46,20 @@ export class PaymentMethodPage extends BasePage {
|
|||
switch (paymentDetails.paymentType) {
|
||||
case PaymentType.Credit:
|
||||
await this.payNowButton.click();
|
||||
await this.textReminderYesButton.click();
|
||||
await this.textReminderNoButton.click();
|
||||
await this.continueToCheckoutButton.click();
|
||||
await this.selectCreditCard(paymentDetails);
|
||||
break;
|
||||
case PaymentType.Paypal:
|
||||
await this.payNowButton.click();
|
||||
await this.textReminderYesButton.click();
|
||||
await this.textReminderNoButton.click();
|
||||
await this.continueToCheckoutButton.click();
|
||||
await this.selectPaypal();
|
||||
await this.paypalPage.completePaypalPurchase(paymentDetails);
|
||||
break;
|
||||
case PaymentType.AfterPay:
|
||||
await this.payInFourButton.click();
|
||||
await this.textReminderYesButton.click();
|
||||
await this.textReminderNoButton.click();
|
||||
await this.continueToCheckoutButton.click();
|
||||
|
||||
// Capture popup
|
||||
|
|
@ -72,7 +72,7 @@ export class PaymentMethodPage extends BasePage {
|
|||
|
||||
case PaymentType.PayAtService:
|
||||
await this.payAtAppointmentButton.click();
|
||||
await this.textReminderYesButton.click();
|
||||
await this.textReminderNoButton.click();
|
||||
await this.submitButton.click();
|
||||
break;
|
||||
default:
|
||||
|
|
@ -94,7 +94,7 @@ export class PaymentMethodPage extends BasePage {
|
|||
}
|
||||
|
||||
async submitOrderWithoutPIA() {
|
||||
await this.textReminderYesButton.click();
|
||||
await this.textReminderNoButton.click();
|
||||
await this.submitButton.click();
|
||||
}
|
||||
}
|
||||
Loading…
Reference in a new issue