Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
This commit is contained in:
1 parent
eae60043bb
commit
4210f35e9c
2 files changed
+30
-5
No files matched your search
@@ -105,11 +105,7 @@ export async function selectSecondAvailableTimeSlotNextMonth(page: Page) {
|
||||
await page.locator('[data-testid="time"]').nth(1).click();
|
||||
}
|
||||
|
||||
export async function bookFirstEvent(page: Page) {
|
||||
// Click first event type
|
||||
|
||||
await page.click('[data-testid="event-type-link"]');
|
||||
|
||||
async function bookEventOnThisPage(page: Page) {
|
||||
await selectFirstAvailableTimeSlotNextMonth(page);
|
||||
await bookTimeSlot(page);
|
||||
|
||||
@@ -122,6 +118,17 @@ export async function bookFirstEvent(page: Page) {
|
||||
await expect(page.locator("[data-testid=success-page]")).toBeVisible();
|
||||
}
|
||||
|
||||
export async function bookOptinEvent(page: Page) {
|
||||
await page.locator('[data-testid="event-type-link"]:has-text("Opt in")').click();
|
||||
await bookEventOnThisPage(page);
|
||||
}
|
||||
|
||||
export async function bookFirstEvent(page: Page) {
|
||||
// Click first event type
|
||||
await page.click('[data-testid="event-type-link"]');
|
||||
await bookEventOnThisPage(page);
|
||||
}
|
||||
|
||||
export const bookTimeSlot = async (page: Page) => {
|
||||
// --- fill form
|
||||
await page.fill('[name="name"]', "Test Testson");
|
||||
|
||||
Reference in new issue
Block a user