diff --git a/playwright-tests/tests/0020_EssentialVehicleLookupBailout.ts b/playwright-tests/tests/0020_EssentialPartQuestionsAndNotShareVin.ts similarity index 65% rename from playwright-tests/tests/0020_EssentialVehicleLookupBailout.ts rename to playwright-tests/tests/0020_EssentialPartQuestionsAndNotShareVin.ts index a70e8da0..1d97684b 100644 --- a/playwright-tests/tests/0020_EssentialVehicleLookupBailout.ts +++ b/playwright-tests/tests/0020_EssentialPartQuestionsAndNotShareVin.ts @@ -1,23 +1,31 @@ import ClientData from "@business-logic/data/ClientData"; import TestCase from "@business-logic/types/TestCase"; -import { DamageType, ServiceLocation, ServicePackage, VehicleDamage, VehicleLookupType } from "@business-logic/types/Enums"; +import { DamageType, ServiceLocation, ServicePackage, VehicleDamage, VehicleLookupType, PartQuestionType } from "@business-logic/types/Enums"; import { ITestData } from "@business-logic/types/ITestData" import { faker } from "@faker-js/faker"; import { getNextWeekday } from "@impl/utils/DateUtils"; const nextWeekday = getNextWeekday(); -const essentialVehicleLookupBailoutData: Partial = { +const essentialPartQuestionsAndNotShareVinData: Partial = { clientTag: 'ALL_ESSENTIAL', isDuplicateClaim: false, isPolicyFound: false, endorsements: [], isReplace: false, - partQuestions: undefined, + partQuestions: [ + { + partQuestionType: PartQuestionType.GeneralQuestion1, + isOnPage: true, + optionToSelect: 'Yes' + }, + { + partQuestionType: PartQuestionType.GeneralQuestion2, + isOnPage: true, + optionToSelect: 'Yes' + } + ], isSafelite: true, - bailoutFlags: { - isVehicleLookupBailout: true - }, servicePackage: faker.helpers.enumValue(ServicePackage), customerDetails: { firstName: faker.person.firstName(), @@ -43,19 +51,10 @@ const essentialVehicleLookupBailoutData: Partial = { year: '2020', make: 'BMW', model: '740', - style: '4 door sedan' // TODO: Check correctness of vehicle style + style: '4 door sedan', + vehicleLookupType: VehicleLookupType.RatherNotShareVin, }, - vehicleDamage: [ - // VehicleDamage.WindshieldThreeChips, - VehicleDamage.WindshieldCrack, - // VehicleDamage.DriverFrontDoor, - // VehicleDamage.DriverQuarterPanel, - // VehicleDamage.DriverRearDoor, - // VehicleDamage.PassengerFrontDoor, - // VehicleDamage.PassengerQuarterPanel, - // VehicleDamage.PassengerRearDoor, - // VehicleDamage.RearWindow - ], + vehicleDamage: [VehicleDamage.WindshieldCrack], appointmentDetails: { serviceLocation: ServiceLocation.InShop, shopAddress: '6826 Sawmill Rd, Columbus, OH 43235', @@ -65,17 +64,17 @@ const essentialVehicleLookupBailoutData: Partial = { } const essentialClients = ClientData.getEssentialClients(); -const essentialVehicleLookupBailoutTests: TestCase[] = []; +const essentialPartQuestionsAndNotShareVinTests: TestCase[] = []; for (const client of essentialClients) { - const data = {...essentialVehicleLookupBailoutData}; + const data = {...essentialPartQuestionsAndNotShareVinData}; data.clientTag = client.clientTag; data.isAuthenticationRequired = client.clientFlags.isAuthenticationEnabled ?? false const tc = new TestCase({ - name: `0020 Essential Vehicle Lookup Bailout Client: "${client.accountName}"`, - tags: [`@${client.clientTag}`, `@${client.accountName}`, '@Bailout', '@VehicleLookup', '@Essentials'], + name: `0020 Essential Part Questions and Not Share Vin Client: "${client.accountName}"`, + tags: [`@${client.clientTag}`, `@${client.accountName}`, '@VehicleLookup', '@Essentials'], testData: data }, undefined, '0020'); - essentialVehicleLookupBailoutTests.push(tc); + essentialPartQuestionsAndNotShareVinTests.push(tc); } -export default essentialVehicleLookupBailoutTests; \ No newline at end of file +export default essentialPartQuestionsAndNotShareVinTests; \ No newline at end of file