Merge pull request #3068 from Safelite/feature/CASH-1252
Added changes that support experiment management in playwright tests
This commit is contained in:
commit
d0a31f8d06
39 changed files with 404 additions and 80 deletions
|
|
@ -5,7 +5,11 @@
|
|||
PLAYWRIGHT_ENV="qa"
|
||||
|
||||
# Skip content site
|
||||
SKIP_CONTENT_SITE=false
|
||||
SKIP_CONTENT_SITE="false"
|
||||
|
||||
# Experiments Flag
|
||||
IS_MOBILEFIRST="false"
|
||||
IS_ADYENPAYMENTS="false"
|
||||
|
||||
# Base URLs by environment
|
||||
# qa
|
||||
|
|
@ -13,7 +17,8 @@ BASE_URL="https://www-qa2.safelite.com/"
|
|||
# local version of FMG (after running the local server)
|
||||
# BASE_URL="http://localhost:8080/fmg/"
|
||||
# qa with skipToInsurance Turned Off
|
||||
# BASE_URL="https://fixmyglassqa.safelite.com/?cns=all&experiments=ConceptFunnel=ConceptFunnel_V1=ConceptFunnel_VinAndEmailOptional=true,NextGen_IGQSkipToInsurance=NextGen_IGQSkipToInsurance_V1=NextGen_IGQSkipToInsurance_CONTROL=true"
|
||||
# BASE_URL="https://fixmyglassqa.safelite.com/?cns=all&experiments=ConceptFunnel=ConceptFunnel_V1=ConceptFunnel_VinAndEmailOptional=true"
|
||||
|
||||
# sys
|
||||
# BASE_URL="https://www-test2.safelite.com/fmg/?fmgPage=vehicle"
|
||||
# dev
|
||||
|
|
|
|||
|
|
@ -5,15 +5,20 @@
|
|||
PLAYWRIGHT_ENV="qa"
|
||||
|
||||
# Skip content site
|
||||
SKIP_CONTENT_SITE=false
|
||||
SKIP_CONTENT_SITE="false"
|
||||
|
||||
# Experiments Flag
|
||||
IS_MOBILEFIRST="false"
|
||||
IS_ADYENPAYMENTS="false"
|
||||
|
||||
# Base URLs by environment
|
||||
# qa
|
||||
# BASE_URL="https://www-qa2.safelite.com/"
|
||||
BASE_URL="https://www-qa2.safelite.com/"
|
||||
# local version of FMG (after running the local server)
|
||||
# BASE_URL="http://localhost:8080/fmg/"
|
||||
# qa with skipToInsurance Turned Off
|
||||
BASE_URL="https://www-qa2.safelite.com/?&experiments=ConceptFunnel=ConceptFunnel_V1=ConceptFunnel_VinAndEmailOptional=true"
|
||||
# BASE_URL="https://www-qa2.safelite.com/?&experiments=ConceptFunnel=ConceptFunnel_V1=ConceptFunnel_VinAndEmailOptional=true"
|
||||
|
||||
# sys
|
||||
# BASE_URL="https://www-test2.safelite.com/fmg/?fmgPage=vehicle"
|
||||
# dev
|
||||
|
|
|
|||
|
|
@ -1,11 +1,22 @@
|
|||
import { ITestData as base } from 'safelite-playwright-core'
|
||||
import { ITestData as base, getDefaultTestData } from 'safelite-playwright-core'
|
||||
import { PaymentMethod } from './localTypes/Enums'
|
||||
import { IExperiments } from './localTypes/IExperiments';
|
||||
|
||||
export interface ITestData extends base {
|
||||
// Put any project-specific data here. Anything useful to other Safelite projects should be submitted as a pull request to safelite-playwright-core.
|
||||
paymentMethod: PaymentMethod,
|
||||
isOptedInForTextMessages: boolean,
|
||||
totalAmount?: number,
|
||||
isForcedOEM?: boolean
|
||||
mockFirstInshopCallNoSchedule?: boolean
|
||||
}
|
||||
isForcedOEM?: boolean,
|
||||
mockFirstInshopCallNoSchedule?: boolean,
|
||||
handleMobileFirstModal?: boolean,
|
||||
experiments?: IExperiments
|
||||
}
|
||||
|
||||
|
||||
export function getDefaultExperimentsData(): IExperiments {
|
||||
return {
|
||||
isAdyenPayments: !!process.env.IS_ADYENPAYMENTS && process.env.IS_ADYENPAYMENTS !== "" ? process.env.IS_ADYENPAYMENTS === "true" : false,
|
||||
isMobileFirst: !!process.env.IS_MOBILEFIRST && process.env.IS_MOBILEFIRST !== "" ? process.env.IS_MOBILEFIRST === "true" : false,
|
||||
}
|
||||
}
|
||||
|
|
|
|||
4
playwright-tests/framework/localTypes/IExperiments.ts
Normal file
4
playwright-tests/framework/localTypes/IExperiments.ts
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
export interface IExperiments {
|
||||
isMobileFirst: boolean,
|
||||
isAdyenPayments: boolean
|
||||
}
|
||||
|
|
@ -142,7 +142,7 @@ export class BasePage {
|
|||
if (!fistInshopScheduleCall) {
|
||||
return route.continue();
|
||||
}
|
||||
|
||||
|
||||
// const fmt = (d: Date) => `${d.getFullYear()}-${String(d.getMonth()+1).padStart(2,"0")}-${String(d.getDate()).padStart(2,"0")}`;
|
||||
// const startDate = new Date();
|
||||
//const beginningOfWeek = new Date(startDate.getFullYear(), startDate.getMonth(), startDate.getDate() - startDate.getDay());
|
||||
|
|
@ -164,7 +164,7 @@ export class BasePage {
|
|||
const responseBody = await response.json();
|
||||
|
||||
responseBody.days = [];
|
||||
|
||||
|
||||
// Mock the response
|
||||
await route.fulfill({
|
||||
response,
|
||||
|
|
@ -228,19 +228,41 @@ export class BasePage {
|
|||
]);
|
||||
}
|
||||
|
||||
async validateOEMPart( isOEM: boolean): Promise<void> {
|
||||
async validateOEMPart(isOEM: boolean): Promise<void> {
|
||||
if (isOEM!) {
|
||||
// Get Vuex state from localStorage
|
||||
const vuexState = JSON.parse(await this.page.evaluate('localStorage.getItem(\'vuex\')'));
|
||||
// Get Vuex state from localStorage
|
||||
const vuexState = JSON.parse(await this.page.evaluate('localStorage.getItem(\'vuex\')'));
|
||||
|
||||
// Validate the presence of an OEM part
|
||||
if (vuexState.order?.lineItems?.glassParts?.length > 0) {
|
||||
const firstGlassPartNumber = vuexState.order.lineItems.glassParts[0].partNumber;
|
||||
// Validate the presence of an OEM part
|
||||
if (vuexState.order?.lineItems?.glassParts?.length > 0) {
|
||||
const firstGlassPartNumber = vuexState.order.lineItems.glassParts[0].partNumber;
|
||||
|
||||
await expect(firstGlassPartNumber.includes("OEM")).toBe(true);
|
||||
await expect(firstGlassPartNumber.includes("OEM")).toBe(true);
|
||||
} else {
|
||||
throw new Error("No glass parts found in the order");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
async buildExperimentUrl(testData: Partial<ITestData>): Promise<string> {
|
||||
|
||||
let experimentsURLExtension = "?cns=all&experiments=";
|
||||
|
||||
const { experiments } = testData;
|
||||
|
||||
if (experiments !== undefined) {
|
||||
experimentsURLExtension += experiments?.isMobileFirst
|
||||
? "MobileFirstAppointment=MobileFirstAppt_V1=MobileFirstAppt_TEST=true"
|
||||
: "MobileFirstAppointment=MobileFirstAppt_V1=MobileFirstAppt_CONTROL=true";
|
||||
|
||||
experimentsURLExtension += experiments?.isAdyenPayments
|
||||
? ",Adyen%20Payments=Adyen%20Payment%20Test=Adyen%20Payment%20(Test)"
|
||||
: ",Adyen%20Payments=Adyen%20Payment%20Test=CyberSource%20(Control)";
|
||||
} else {
|
||||
throw new Error("No glass parts found in the order");
|
||||
console.log("Url extension without query string");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Convert to HTML encoding before returning
|
||||
return experimentsURLExtension;
|
||||
}
|
||||
}
|
||||
|
|
@ -1,5 +1,6 @@
|
|||
import test, { expect, type Locator, type Page } from '@playwright/test';
|
||||
import { BasePage } from './BasePage';
|
||||
import { ITestData } from 'framework/TestData';
|
||||
|
||||
export class HomePage extends BasePage {
|
||||
|
||||
|
|
@ -51,8 +52,9 @@ export class HomePage extends BasePage {
|
|||
this.getQuoteAndScheduleButton = this.page.getByLabel('main').getByRole('link', { name: 'Get quote + schedule' });
|
||||
}
|
||||
|
||||
async goto() {
|
||||
await this.page.goto(process.env['BASE_URL']!);
|
||||
async goto(testData: Partial<ITestData>) {
|
||||
const experimentUrlExtension = await this.buildExperimentUrl(testData);
|
||||
await this.page.goto(process.env['BASE_URL']! + experimentUrlExtension);
|
||||
}
|
||||
|
||||
async isCurrentVariant(): Promise<boolean> {
|
||||
|
|
@ -75,6 +77,4 @@ export class HomePage extends BasePage {
|
|||
}
|
||||
await this.letsGetStartedButton.click();
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
@ -108,7 +108,7 @@ export class OrderConfirmationPage extends BasePage {
|
|||
}
|
||||
}
|
||||
|
||||
async getFormattedAppointmentDate(appointmentDate: string) {
|
||||
/*async getFormattedAppointmentDate(appointmentDate: string) {
|
||||
|
||||
// Parse the original date
|
||||
let parsedAppointmentDate = new Date(`${appointmentDate}` + 'T00:00:00');
|
||||
|
|
@ -116,6 +116,24 @@ export class OrderConfirmationPage extends BasePage {
|
|||
// Format the new date as a string
|
||||
let updatedAppointmentDate = parsedAppointmentDate.toLocaleDateString('en-US', { weekday: 'long', month: 'long', day: 'numeric' });
|
||||
return updatedAppointmentDate;
|
||||
}*/
|
||||
|
||||
async getFormattedAppointmentDate(appointmentDate: string) {
|
||||
let formattedAppointmentDate: string;
|
||||
|
||||
switch (true) {
|
||||
case /^\d{4}-\d{2}-\d{2}$/.test(appointmentDate):
|
||||
let parsedAppointmentDate = new Date(`${appointmentDate}` + 'T00:00:00');
|
||||
formattedAppointmentDate = parsedAppointmentDate.toLocaleDateString('en-US', { weekday: 'long', month: 'long', day: 'numeric' });
|
||||
break;
|
||||
case /[A-Za-z]+,\s+[A-Za-z]+\s+\d{1,2}/.test(appointmentDate):
|
||||
formattedAppointmentDate = appointmentDate;
|
||||
break;
|
||||
default:
|
||||
throw new Error('Unsupported date format: ' + appointmentDate);
|
||||
}
|
||||
|
||||
return formattedAppointmentDate;
|
||||
}
|
||||
|
||||
async toggleOrderDetailsSection() {
|
||||
|
|
|
|||
|
|
@ -487,7 +487,7 @@ export class PaymentMethodPage extends BasePage {
|
|||
}
|
||||
}
|
||||
|
||||
async getFormattedAppointmentDate(appointmentDate: string) {
|
||||
/*async getFormattedAppointmentDate(appointmentDate: string) {
|
||||
|
||||
// Parse the original date
|
||||
let parsedAppointmentDate = new Date(`${appointmentDate}` + 'T00:00:00');
|
||||
|
|
@ -495,8 +495,36 @@ export class PaymentMethodPage extends BasePage {
|
|||
// Format the new date as a string
|
||||
let updatedAppointmentDate = parsedAppointmentDate.toLocaleDateString('en-US', { weekday: 'long', year: 'numeric', month: 'long', day: 'numeric' });
|
||||
return updatedAppointmentDate;
|
||||
}*/
|
||||
|
||||
async getFormattedAppointmentDate(appointmentDate: string) {
|
||||
let formattedAppointmentDate: Date;
|
||||
const now = new Date();
|
||||
|
||||
switch (true) {
|
||||
case /^\d{4}-\d{2}-\d{2}$/.test(appointmentDate):
|
||||
formattedAppointmentDate = new Date(appointmentDate + 'T00:00:00');
|
||||
break;
|
||||
|
||||
case /[A-Za-z]+,\s+[A-Za-z]+\s+\d{1,2}/.test(appointmentDate):
|
||||
const [, month, day] = appointmentDate.match(/[A-Za-z]+,\s+([A-Za-z]+)\s+(\d{1,2})/) || [];
|
||||
formattedAppointmentDate = new Date(`${month} ${day}, ${now.getFullYear()}`);
|
||||
if (formattedAppointmentDate < now) formattedAppointmentDate.setFullYear(now.getFullYear() + 1); // rollover
|
||||
break;
|
||||
|
||||
default:
|
||||
throw new Error('Unsupported date format: ' + appointmentDate);
|
||||
}
|
||||
|
||||
return formattedAppointmentDate.toLocaleDateString('en-US', {
|
||||
weekday: 'long',
|
||||
year: 'numeric',
|
||||
month: 'long',
|
||||
day: 'numeric'
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@step("PaymentMethodPage >> Select Payment Method: ")
|
||||
async handlePaymentMethodPage(testData: Partial<ITestData>) {
|
||||
const { servicePackage, isRecalVehicle, paymentDetails, isForcedOEM } = testData;
|
||||
|
|
@ -505,7 +533,7 @@ export class PaymentMethodPage extends BasePage {
|
|||
await this.validatePaymentDetailsPage(testData);
|
||||
await this.ValidateAfterPayBreakOutSection();
|
||||
|
||||
if (isForcedOEM){
|
||||
if (isForcedOEM) {
|
||||
await this.validateOEMPart(isForcedOEM);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -39,6 +39,7 @@ export class SchedulePage extends BasePage {
|
|||
readonly yesButtonRecalAckModal: Locator;
|
||||
readonly noButtonRecalAckModal: Locator;
|
||||
readonly continueButtonRecalAckModal: Locator;
|
||||
readonly mobileFirstModal: Locator;
|
||||
|
||||
constructor(page: Page) {
|
||||
super(page);
|
||||
|
|
@ -73,6 +74,7 @@ export class SchedulePage extends BasePage {
|
|||
this.yesButtonRecalAckModal = this.page.locator("label[buttonlabel='Yes']");
|
||||
this.noButtonRecalAckModal = this.page.locator("label[buttonlabel='No']");
|
||||
this.continueButtonRecalAckModal = this.page.locator("#recal-ack-modal-container .modal-footer button");
|
||||
this.mobileFirstModal = this.page.locator("#mobile-first-modal-container");
|
||||
}
|
||||
|
||||
async selectLocation(testData: Partial<ITestData>) {
|
||||
|
|
@ -234,17 +236,32 @@ export class SchedulePage extends BasePage {
|
|||
return formattedTimeSlot;
|
||||
}
|
||||
|
||||
async handleMobileFirstPopUp(testData: Partial<ITestData>) {
|
||||
|
||||
const { customerDetails } = testData;
|
||||
customerDetails!.apptDate = (await this.mobileFirstModal.locator('li', { hasText: 'Date:' }).innerText()).replace('Date:', '').trim();
|
||||
customerDetails!.apptTime = (await this.mobileFirstModal.locator('li', { hasText: 'Appointment window:' }).innerText()).replace('Appointment window:', 'arriving between').trim();
|
||||
customerDetails!.apptDuration = (await this.mobileFirstModal.locator('li', { hasText: 'Estimate length:' }).innerText()).replace('Estimate length:', '').trim();
|
||||
|
||||
await this.mobileFirstModal.getByRole("button", { name: 'Confirm appointment'}).click();
|
||||
}
|
||||
|
||||
@step("SchedulePage >> Schedule appointment: ")
|
||||
async handleSchedulePage(testData: Partial<ITestData>) {
|
||||
const { appointmentDetails, isCanNotRecal } = testData;
|
||||
const { appointmentDetails, isCanNotRecal, experiments, handleMobileFirstModal } = testData;
|
||||
await this.waitForPageOrComponentload();
|
||||
await this.validateProgressBar(ProgressBarPercentages.SchedulePage);
|
||||
if (await this.mobileFirstModalCloseButton.isVisible()) {
|
||||
|
||||
if (handleMobileFirstModal) {
|
||||
return await this.handleMobileFirstPopUp(testData);
|
||||
}
|
||||
|
||||
if (experiments?.isMobileFirst && await this.mobileFirstModalCloseButton.isVisible()) {
|
||||
await this.mobileFirstModalCloseButton.click();
|
||||
}
|
||||
await this.selectLocation(testData);
|
||||
|
||||
if (await this.mobileFirstModalCloseButton.isVisible({timeout: 5000})) {
|
||||
if (experiments?.isMobileFirst && await this.mobileFirstModalCloseButton.isVisible({timeout: 5000})) {
|
||||
await this.page.waitForTimeout(1000);
|
||||
await this.mobileFirstModalCloseButton.dblclick();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -78,7 +78,7 @@ export default defineConfig({
|
|||
/* Retry on CI only */
|
||||
retries: process.env.CI ? 1 : 0,
|
||||
/* Opt out of parallel tests on CI. */
|
||||
workers: process.env.CI ? 4 : 5,
|
||||
workers: process.env.CI ? 4 : 3,
|
||||
/* Reporter to use. See https://playwright.dev/docs/test-reporters */
|
||||
reporter: process.env.CI? [
|
||||
['junit'],
|
||||
|
|
|
|||
|
|
@ -32,6 +32,7 @@ import insuranceNoCompProgressiveTests from "./InsuranceNoCompProgressive";
|
|||
import insuranceOEMAllstateTests from "./InsuranceOEMAllState";
|
||||
import cashRepairInShopAfterPayTests from "./CashRepairInShopAfterPay";
|
||||
import cashRepairInShopPayPalTests from "./CashRepairInShopPayPal";
|
||||
import cashReplaceMobileFirstModalTests from "./CashReplaceMobileFirstModal";
|
||||
import cashReplaceMultiSlidingGlassDropoffTests from "./CashReplaceMultiSlidingGlassDropoff";
|
||||
import cashReplaceMultiGlassMobileTests from "./CashReplaceMultiGlassMobile";
|
||||
import { getTestObject, TestCase, prepareTest, RuleEngine, TestInfo } from 'framework/Typedefs';
|
||||
|
|
@ -79,6 +80,7 @@ const allStandardTests = [
|
|||
{ name: "CashReplaceStaticInshop", tests: cashReplaceStaticInshopTests },
|
||||
{ name: "CashReplaceWiperPromoInshop", tests: cashReplaceWiperPromoInShopTests },
|
||||
{ name: "CashReplaceSwitchToInsuranceProgressiveNoComp", tests: cashReplaceSwitchToInsuranceProgressiveNoCompTests },
|
||||
{ name: "CashReplaceMobileFirstModal", tests: cashReplaceMobileFirstModalTests },
|
||||
// TODO: Uncomment when QA is ready to run heavy truck tests
|
||||
// {name: "CashReplaceSplitWindshield", tests: CashReplaceSplitWindshieldTests},
|
||||
{ name: "InsuranceAcuityPaypal", tests: insuranceAcuityPaypalTests },
|
||||
|
|
@ -142,7 +144,7 @@ async function run(page: Page, testInfo: TestInfo): Promise<void> {
|
|||
try {
|
||||
await testInfo.testCase.setup();
|
||||
testInfo.testCase.setupPages(page, createTestPages);
|
||||
await testInfo.testCase.pages.homePage.goto();
|
||||
await testInfo.testCase.pages.homePage.goto(testInfo.testCase.testData);
|
||||
await runWorkflow(page, testInfo.testCase);
|
||||
} catch (error) {
|
||||
// Catch successful alert tests and log message
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { VehicleDamage, ServiceLocation, ServicePackage } from 'safelite-playwright-core';
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { ClientData } from 'safelite-playwright-core';
|
||||
|
|
@ -34,7 +34,12 @@ const cashRepairInShopAfterPayData : Partial<ITestData> = {
|
|||
},
|
||||
|
||||
// Use predefined payment data
|
||||
paymentDetails: ClientData.getDefaultAfterpayDetails()
|
||||
paymentDetails: ClientData.getDefaultAfterpayDetails(),
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const cashRepairInShopAfterPayTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { VehicleDamage, ServicePackage } from 'safelite-playwright-core';
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { ClientData } from 'safelite-playwright-core';
|
||||
|
|
@ -35,7 +35,12 @@ const cashRepairInShopPayPalData : Partial<ITestData> = {
|
|||
},
|
||||
|
||||
// Use predefined payment data
|
||||
paymentDetails: ClientData.getDefaultPaypalDetails()
|
||||
paymentDetails: ClientData.getDefaultPaypalDetails(),
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const cashRepairInShopPayPalTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { VehicleDamage, ServiceLocation } from 'safelite-playwright-core';
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { ClientData } from 'safelite-playwright-core';
|
||||
|
|
@ -48,7 +48,12 @@ const cashRepairMobileCCData : Partial<ITestData> = {
|
|||
},
|
||||
|
||||
// Use predefined payment data
|
||||
paymentDetails: ClientData.getDefaultCreditCardDetails()
|
||||
paymentDetails: ClientData.getDefaultCreditCardDetails(),
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const cashRepairMobileCCTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { ServiceLocation, ServicePackage, PaymentType } from 'safelite-playwright-core';
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { VehicleLookupType } from 'safelite-playwright-core';
|
||||
|
|
@ -63,6 +63,11 @@ const cashReplaceDynamicRecalMobileData: Partial<ITestData> = {
|
|||
paymentType: PaymentType.PayAtService,
|
||||
// promoCode: 'digitalrain'
|
||||
promoCode: 'rain50'
|
||||
},
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { VehicleLookupType } from 'safelite-playwright-core';
|
||||
import { ClientData } from 'safelite-playwright-core';
|
||||
|
|
@ -43,7 +43,12 @@ const cashReplaceGlassAddressLookupInshopAfterPayData: Partial<ITestData> = {
|
|||
},
|
||||
|
||||
// Override payment details
|
||||
paymentDetails: ClientData.getDefaultAfterpayDetails()
|
||||
paymentDetails: ClientData.getDefaultAfterpayDetails(),
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const cashReplaceGlassAddressLookupInshopAfterPayTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { VehicleLookupType } from 'safelite-playwright-core';
|
||||
import { ClientData } from 'safelite-playwright-core';
|
||||
|
|
@ -42,7 +42,12 @@ const cashReplaceGlassLicensePlateLookupInshopPaypalData: Partial<ITestData> = {
|
|||
// No need to override vehicleDamage as it already defaults to WindshieldCrack
|
||||
|
||||
// Override payment details to use PayPal
|
||||
paymentDetails: ClientData.getDefaultPaypalDetails()
|
||||
paymentDetails: ClientData.getDefaultPaypalDetails(),
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const cashReplaceGlassLicensePlateLookupInshopPaypalTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { PaymentType } from 'safelite-playwright-core';
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { VehicleLookupType } from 'safelite-playwright-core';
|
||||
|
|
@ -55,6 +55,11 @@ const cashReplaceGlassPromoInshopData: Partial<ITestData> = {
|
|||
paymentType: PaymentType.PayAtService,
|
||||
// Add promo code - key feature of this test
|
||||
promoCode: '20CALL',
|
||||
},
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
79
playwright-tests/tests/CashReplaceMobileFirstModal.ts
Normal file
79
playwright-tests/tests/CashReplaceMobileFirstModal.ts
Normal file
|
|
@ -0,0 +1,79 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ServiceLocation, ServicePackage, PaymentType, PartQuestionType } from 'safelite-playwright-core';
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { VehicleLookupType } from 'safelite-playwright-core';
|
||||
import { getDefaultTestData, setFakerSeedFromTestName } from 'safelite-playwright-core';
|
||||
import { PaymentMethod } from 'framework/localTypes/Enums';
|
||||
|
||||
// Set the seed before generating any data
|
||||
setFakerSeedFromTestName("CashReplaceMobileFirstModal");
|
||||
|
||||
// Now get the test data with the seeded faker
|
||||
const cashReplaceMobileFirstModalData: Partial<ITestData> = {
|
||||
...getDefaultTestData(), // Get default data with current seed
|
||||
|
||||
// CASH Client
|
||||
paymentMethod: PaymentMethod.SelfPay,
|
||||
|
||||
customerDetails: {
|
||||
...getDefaultTestData().customerDetails!,
|
||||
address: {
|
||||
...getDefaultTestData().customerDetails!.address,
|
||||
postalCode: '91761'
|
||||
}
|
||||
},
|
||||
|
||||
servicePackage: ServicePackage.GlassOnly,
|
||||
// Override vehicle details
|
||||
vehicleDetails: {
|
||||
...getDefaultTestData().vehicleDetails!,
|
||||
year: '2018',
|
||||
make: 'Honda',
|
||||
model: 'Accord',
|
||||
style: '4 door sedan',
|
||||
},
|
||||
|
||||
handleMobileFirstModal: true,
|
||||
|
||||
partQuestions: [
|
||||
{
|
||||
partQuestionType: PartQuestionType.GeneralQuestion1,
|
||||
isOnPage: true,
|
||||
optionToSelect: 'Yes'
|
||||
},
|
||||
],
|
||||
|
||||
mockFirstInshopCallNoSchedule: true,
|
||||
// No need to override vehicleDamage as it already defaults to WindshieldCrack
|
||||
|
||||
// Override appointment details
|
||||
appointmentDetails: {
|
||||
serviceLocation: ServiceLocation.Mobile,
|
||||
appointmentDate: getDefaultTestData().appointmentDetails?.appointmentDate,
|
||||
serviceAddress: {
|
||||
// Use street address from current faker seed
|
||||
street: "2064 S Sultana Ave",
|
||||
city: 'Ontario',
|
||||
state: 'CA',
|
||||
postalCode: '91761',
|
||||
country: 'United States'
|
||||
},
|
||||
},
|
||||
|
||||
// Override payment details
|
||||
paymentDetails: {
|
||||
paymentType: PaymentType.PayAtService
|
||||
}
|
||||
}
|
||||
|
||||
const cashReplaceMobileFirstModal: ITestCase[] = [];
|
||||
|
||||
const tc = {
|
||||
name: `CashReplaceMobileFirstModal`,
|
||||
tags: ['@E2E','@CashReplaceMobileFirstModal', '@test_report', '@CASH'],
|
||||
testData: cashReplaceMobileFirstModalData
|
||||
};
|
||||
cashReplaceMobileFirstModal.push(tc);
|
||||
|
||||
export default cashReplaceMobileFirstModal;
|
||||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { VehicleDamage, PartQuestionType, PaymentType, ServicePackage, ServiceLocation } from 'safelite-playwright-core';
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { VehicleLookupType } from 'safelite-playwright-core';
|
||||
|
|
@ -88,7 +88,12 @@ const cashReplaceMultiGlassMobileData: Partial<ITestData> = {
|
|||
optionToSelect: 'Gray Tint Privacy',
|
||||
secondaryQuestionOptionToSelect: 'solar, passenger side, encap, chrome molding'
|
||||
}
|
||||
]
|
||||
],
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const cashReplaceMultiGlassMobileTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { VehicleDamage, PartQuestionType, PaymentType } from 'safelite-playwright-core';
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { VehicleLookupType } from 'safelite-playwright-core';
|
||||
|
|
@ -94,7 +94,12 @@ const cashReplaceMultiGlassPromoInshopData: Partial<ITestData> = {
|
|||
optionToSelect: 'Green Tint',
|
||||
secondaryQuestionOptionToSelect: 'heated glass, solar, antenna, manual liftgate, 1 hole'
|
||||
}
|
||||
]
|
||||
],
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const cashReplaceMultiGlassPromoInshopTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { VehicleDamage, PartQuestionType, PaymentType, ServicePackage, ServiceLocation } from 'safelite-playwright-core';
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { VehicleLookupType } from 'safelite-playwright-core';
|
||||
|
|
@ -105,7 +105,12 @@ const cashReplaceMultiSlidingGlassDropoffData: Partial<ITestData> = {
|
|||
optionToSelect: 'Gray Tint Privacy',
|
||||
secondaryQuestionOptionToSelect: 'heated glass, solar, slider, power, kit'
|
||||
}
|
||||
]
|
||||
],
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const cashReplaceMultiSlidingGlassDropoffTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { ServicePackage, PaymentType } from 'safelite-playwright-core';
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { VehicleLookupType } from 'safelite-playwright-core';
|
||||
|
|
@ -50,6 +50,11 @@ const cashReplaceRainDefensePromoInshopData: Partial<ITestData> = {
|
|||
// Rain Defense promo code
|
||||
promoCode: 'rd50'
|
||||
},
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const cashReplaceRainDefensePromoInshopTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { ServiceLocation, PartQuestionType, PaymentType } from 'safelite-playwright-core';
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { VehicleLookupType } from 'safelite-playwright-core';
|
||||
|
|
@ -70,7 +70,12 @@ const cashReplaceSafeliteCanNotRecalMobileData: Partial<ITestData> = {
|
|||
isOnPage: true,
|
||||
optionToSelect: 'Yes'
|
||||
},
|
||||
]
|
||||
],
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const cashReplaceSafeliteCanNotRecalMobileTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { PartQuestionType, PaymentType, VehicleDamage } from 'safelite-playwright-core';
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { VehicleLookupType } from 'safelite-playwright-core';
|
||||
|
|
@ -59,6 +59,11 @@ const CashReplaceSplitWindshieldData: Partial<ITestData> = {
|
|||
// Override payment details
|
||||
paymentDetails: {
|
||||
paymentType: PaymentType.PayAtService
|
||||
},
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { ServicePackage, PaymentType, PartQuestionType } from 'safelite-playwright-core';
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { VehicleLookupType } from 'safelite-playwright-core';
|
||||
|
|
@ -64,6 +64,11 @@ const CashReplaceStaticInshopData: Partial<ITestData> = {
|
|||
paymentDetails: {
|
||||
paymentType: PaymentType.PayAtService
|
||||
},
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const cashReplaceStaticInshopTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { Flow, ServiceLocation } from "safelite-playwright-core";
|
||||
import { DamageType, PartQuestionType, PaymentType } from 'safelite-playwright-core'
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
|
|
@ -70,7 +70,10 @@ const cashReplaceSwitchToInsuranceProgressiveNoCompData: Partial<ITestData> = {
|
|||
appointmentDate: getDefaultTestData().appointmentDetails?.appointmentDate,
|
||||
},
|
||||
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
};
|
||||
|
||||
// Create and register the test case
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { AppointmentTimeslot, ServiceLocation, PaymentType } from 'safelite-playwright-core';
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { VehicleLookupType } from 'safelite-playwright-core';
|
||||
|
|
@ -60,6 +60,11 @@ const cashReplaceVinMobileData: Partial<ITestData> = {
|
|||
paymentDetails: {
|
||||
paymentType: PaymentType.PayAtService
|
||||
},
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const cashReplaceVinMobileTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { ServicePackage, ServiceLocation, PartQuestionType, PaymentType } from 'safelite-playwright-core';
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { VehicleLookupType } from 'safelite-playwright-core';
|
||||
|
|
@ -69,7 +69,12 @@ const cashReplaceWiperDropoffData: Partial<ITestData> = {
|
|||
isOnPage: true,
|
||||
optionToSelect: 'Yes'
|
||||
},
|
||||
]
|
||||
],
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const cashReplaceWiperDropoffTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { ServicePackage, ServiceLocation, PaymentType } from 'safelite-playwright-core';
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { VehicleLookupType } from 'safelite-playwright-core';
|
||||
|
|
@ -46,6 +46,11 @@ const cashReplaceWiperPromoInShopData: Partial<ITestData> = {
|
|||
paymentType: PaymentType.PayAtService,
|
||||
// Specific wiper promo code
|
||||
promoCode: '1WIPER0',
|
||||
},
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { ServiceLocation, DamageType, PartQuestionType, VehicleDamage, PaymentType, Flow } from 'safelite-playwright-core';
|
||||
import { PaymentMethod } from "framework/localTypes/Enums";
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
|
|
@ -83,7 +83,12 @@ const insuranceAcuityPaypalData: Partial<ITestData> = {
|
|||
],
|
||||
|
||||
// Override payment details (empty because we skip payment method page in insurance flow)
|
||||
paymentDetails: {}
|
||||
paymentDetails: {},
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const insuranceAcuityPaypalTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { ServiceLocation, DamageType, PaymentType, PartQuestionType } from 'safelite-playwright-core';
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { PaymentMethod } from "framework/localTypes/Enums";
|
||||
|
|
@ -67,7 +67,12 @@ const insuranceBigTruckVerifiedData: Partial<ITestData> = {
|
|||
},
|
||||
|
||||
// Override payment details (empty because we skip payment method page in insurance flow)
|
||||
paymentDetails: {}
|
||||
paymentDetails: {},
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const insuranceBigTruckVerifiedTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { ServiceLocation, DamageType, Flow } from 'safelite-playwright-core';
|
||||
import { PaymentMethod } from "framework/localTypes/Enums";
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
|
|
@ -64,7 +64,12 @@ const insuranceGeicoData: Partial<ITestData> = {
|
|||
},
|
||||
|
||||
// Override payment details (empty because we skip payment method page in insurance flow)
|
||||
paymentDetails: {}
|
||||
paymentDetails: {},
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const insuranceGeicoTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { ServiceLocation, DamageType, PartQuestionType, Flow } from 'safelite-playwright-core';
|
||||
import { PaymentMethod } from "framework/localTypes/Enums";
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
|
|
@ -68,7 +68,12 @@ const insuranceITAC21stCenturyData: Partial<ITestData> = {
|
|||
isOnPage: true,
|
||||
optionToSelect: 'Yes'
|
||||
},
|
||||
]
|
||||
],
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const insuranceITAC21stCenturyTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { VehicleDamage, ServiceLocation, DamageType, Flow } from 'safelite-playwright-core';
|
||||
import { PaymentMethod } from "framework/localTypes/Enums";
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
|
|
@ -65,7 +65,12 @@ const insuranceITACOptimizedPriceValidationAllStateData: Partial<ITestData> = {
|
|||
appointmentDate: getDefaultTestData().appointmentDetails?.appointmentDate
|
||||
},
|
||||
// Override payment details (empty because we skip payment method page in insurance flow)
|
||||
paymentDetails: {}
|
||||
paymentDetails: {},
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const insuranceITACOptimizedPriceValidationAllStateTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { ServiceLocation, DamageType, Flow, PartQuestionType, LossLocation } from 'safelite-playwright-core';
|
||||
import { PaymentMethod } from "framework/localTypes/Enums";
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
|
|
@ -62,7 +62,12 @@ const insuranceMeemicNearSchoolVerifiedData: Partial<ITestData> = {
|
|||
],
|
||||
|
||||
// Override payment details (empty because we skip payment method page in insurance flow)
|
||||
paymentDetails: {}
|
||||
paymentDetails: {},
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
};
|
||||
|
||||
const insuranceMeemicNearSchoolVerifiedTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { ServiceLocation, DamageType, PaymentType, PartQuestionType, Flow } from 'safelite-playwright-core';
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { PaymentMethod } from "framework/localTypes/Enums";
|
||||
|
|
@ -77,7 +77,12 @@ const insuranceNoCompProgressiveData: Partial<ITestData> = {
|
|||
},
|
||||
|
||||
// Override payment details (empty because we skip payment method page in insurance flow)
|
||||
paymentDetails: {}
|
||||
paymentDetails: {},
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const insuranceNoCompProgressiveTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { ServiceLocation, DamageType, PaymentType, PartQuestionType } from 'safelite-playwright-core';
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { PaymentMethod } from "framework/localTypes/Enums";
|
||||
|
|
@ -73,7 +73,12 @@ const insuranceOEMAllstateData: Partial<ITestData> = {
|
|||
},
|
||||
|
||||
// Override payment details (empty because we skip payment method page in insurance flow)
|
||||
paymentDetails: {}
|
||||
paymentDetails: {},
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const insuranceOEMAllstateTests: ITestCase[] = [];
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
//Imports here
|
||||
import { ITestData } from 'framework/TestData'
|
||||
import { ITestData, getDefaultExperimentsData } from 'framework/TestData'
|
||||
import { ServiceLocation, DamageType, PaymentType, PartQuestionType } from 'safelite-playwright-core';
|
||||
import { ITestCase } from '../framework/Typedefs'
|
||||
import { PaymentMethod } from "framework/localTypes/Enums";
|
||||
|
|
@ -72,7 +72,12 @@ const insuranceUnverifiedData: Partial<ITestData> = {
|
|||
},
|
||||
|
||||
// Override payment details (empty because we skip payment method page in insurance flow)
|
||||
paymentDetails: {}
|
||||
paymentDetails: {},
|
||||
|
||||
// Experiments
|
||||
experiments: {
|
||||
...getDefaultExperimentsData()
|
||||
}
|
||||
}
|
||||
|
||||
const insuranceUnverifiedTests: ITestCase[] = [];
|
||||
|
|
|
|||
Loading…
Reference in a new issue