DigitalConsumer.FixMyGlass/playwright-tests/pages/VehiclePartsPage.ts
2025-05-23 11:58:33 -04:00

23 lines
No EOL
920 B
TypeScript

import { Page } from "@playwright/test";
import { PartQuestionsPage } from "./PartQuestionPage";
import { step } from "@business-logic/types/Step";
import { ITestData } from "@business-logic/types/ITestData";
import { ProgressBarPercentages } from "@business-logic/types/Enums";
export default class VehiclePartQuestionsPage extends PartQuestionsPage{
url = process.env['BASE_URL']! + '/fmg/?fmgPage=vehicle-parts';
constructor(page: Page) {
super(page);
}
@step("VehiclePartsPage >> Select Vehicle Part Questions: ")
async handleVehiclePartsPage(testCase: Partial<ITestData>) {
const { vehiclePartQuestions } = testCase;
await this.validateProgressBar(ProgressBarPercentages.VehiclePartsPage);
await this.validatePartQuestions(vehiclePartQuestions!);
await this.selectPartQuestionResponses(vehiclePartQuestions!);
await this.nextPage();
}
}