DigitalConsumer.FixMyGlass/playwright-tests/tests/alert-validation/alert0001_HeavyTruck.ts
maguire-arman a2ca9134d1 Initializes Playwright test framework
Sets up the core infrastructure for Playwright-based automated testing, including:
- Docker support for consistent environments
- Azure Pipelines configuration for CI/CD
- Page Object Model structure for maintainable tests
- Test data, validation, and rule engine implementation
- Test configuration for alerts and other scenarios
2025-05-08 15:45:05 -04:00

42 lines
No EOL
1.2 KiB
TypeScript

//Imports here
import { ITestData } from "@business-logic/types/ITestData"
import { VehicleDamage, AppointmentType } from "@business-logic/types/Enums";
import TestCase from "@business-logic/types/TestCase";
import { getNextWeekday } from "@impl/utils/DateUtils";
import { defaultTestData } from "@business-logic/constants/DefaultTestData";
// Heavy Truck (alert) Test Data
const heavyTruckData: Partial<ITestData> = {
...defaultTestData, // Start with all defaults
// Override specific fields with test-specific data
vehicleDetails: {
...defaultTestData.vehicleDetails!,
year: '2017',
make: 'Freightliner',
model: '114sd',
style: 'conventional cab'
},
alertFlags: {
isHeavyTruckVehicle: true
},
vehicleDamage: [
VehicleDamage.WindshieldOneChip,
VehicleDamage.RearWindow
],
appointmentDetails: {
serviceLocation: AppointmentType.DropOff,
appointmentDate: getNextWeekday()
}
};
const heavyTruckTests: TestCase[] = [];
const tc = new TestCase({
name: `alert0001 Heavy Truck`,
tags: ['@Alert', '@HeavyTruck', '@test_report'],
testData: heavyTruckData
}, undefined, 'HeavyTruck');
heavyTruckTests.push(tc);
export default heavyTruckTests;