mirror of
https://github.com/CompassConnections/Compass.git
synced 2026-03-25 18:13:48 -04:00
* Test * Add pretty formatting * Fix Tests * Fix Tests * Fix Tests * Fix * Add pretty formatting fix * Fix * Test * Fix tests * Clean typeckech * Add prettier check * Fix api tsconfig * Fix api tsconfig * Fix tsconfig * Fix * Fix * Prettier
53 lines
1.7 KiB
TypeScript
53 lines
1.7 KiB
TypeScript
import {expect, Locator, Page} from '@playwright/test'
|
|
|
|
export class OnboardingPage {
|
|
private readonly continueButton: Locator
|
|
private readonly skipOnboardingLink: Locator
|
|
private readonly backButton: Locator
|
|
private readonly getStartedButton: Locator
|
|
private readonly exploreProfilesNowButton: Locator
|
|
private readonly refineProfileButton: Locator
|
|
|
|
constructor(public readonly page: Page) {
|
|
this.continueButton = page.getByRole('button', {name: 'Continue', exact: true})
|
|
this.skipOnboardingLink = page.getByRole('button', {name: 'Skip onboarding', exact: true})
|
|
this.backButton = page.getByRole('button', {name: 'Back'})
|
|
this.getStartedButton = page.getByRole('button', {name: 'Get started'})
|
|
this.exploreProfilesNowButton = page.getByRole('button', {
|
|
name: 'Explore Profiles Now',
|
|
exact: true,
|
|
})
|
|
this.refineProfileButton = page.getByRole('button', {name: 'Refine Profile', exact: true})
|
|
}
|
|
|
|
async clickContinueButton() {
|
|
await expect(this.continueButton).toBeVisible()
|
|
await this.continueButton.click()
|
|
}
|
|
|
|
async clickBackButton() {
|
|
await expect(this.backButton).toBeVisible()
|
|
await this.backButton.click()
|
|
}
|
|
|
|
async clickSkipOnboardingButton() {
|
|
await expect(this.skipOnboardingLink).toBeVisible()
|
|
await this.skipOnboardingLink.click()
|
|
}
|
|
|
|
async clickGetStartedButton() {
|
|
await expect(this.getStartedButton).toBeVisible()
|
|
await this.getStartedButton.click()
|
|
}
|
|
|
|
async clickExploreProfilesNowButton() {
|
|
await expect(this.exploreProfilesNowButton).toBeVisible()
|
|
await this.exploreProfilesNowButton.click()
|
|
}
|
|
|
|
async clickRefineProfileButton() {
|
|
await expect(this.refineProfileButton).toBeVisible()
|
|
await this.refineProfileButton.click()
|
|
}
|
|
}
|