add localize / refactor
This commit is contained in:
parent
717e60b9dc
commit
99285079c7
|
@ -2,6 +2,7 @@ import { randomString } from "@calcom/lib/random";
|
|||
|
||||
import { loginUser } from "../../fixtures/regularBookings";
|
||||
import { test } from "../../lib/fixtures";
|
||||
import { localize } from "../../lib/testUtils";
|
||||
|
||||
test.describe("Create a Team, a Collective Event Type and Book a Meeting", () => {
|
||||
test.beforeEach(async ({ page, users }) => {
|
||||
|
@ -11,6 +12,7 @@ test.describe("Create a Team, a Collective Event Type and Book a Meeting", () =>
|
|||
|
||||
test("Create Collective Event type and Book a Meeting", async ({ bookingPage }) => {
|
||||
const teamName = `Team example-${randomString(3)}`;
|
||||
const backToBookingsText = (await localize("en"))("back_to_bookings");
|
||||
|
||||
await bookingPage.createTeam(teamName);
|
||||
await bookingPage.createTeamEventType("test-collective", { isCollectiveType: true });
|
||||
|
@ -18,7 +20,7 @@ test.describe("Create a Team, a Collective Event Type and Book a Meeting", () =>
|
|||
await bookingPage.selectTimeSlot(eventTypePage);
|
||||
|
||||
await bookingPage.confirmBooking(eventTypePage);
|
||||
await bookingPage.goToPage("Back to bookings", eventTypePage);
|
||||
await bookingPage.goToPage(backToBookingsText, eventTypePage);
|
||||
await bookingPage.assertLabelWithCorrectTeamName(eventTypePage, teamName);
|
||||
await bookingPage.assertBookingWithCorrectTitleAndDescription(eventTypePage, {
|
||||
profileName: "testuser",
|
||||
|
@ -35,6 +37,7 @@ test.describe("Create a Team, a Collective Event Type and Book a Meeting", () =>
|
|||
|
||||
test("Create Collective Event type and Book a Meeting (with added guest)", async ({ bookingPage }) => {
|
||||
const teamName = `Team example-${randomString(3)}`;
|
||||
const backToBookingsText = (await localize("en"))("back_to_bookings");
|
||||
|
||||
await bookingPage.createTeam(teamName);
|
||||
await bookingPage.createTeamEventType("test-collective", { isCollectiveType: true });
|
||||
|
@ -42,7 +45,7 @@ test.describe("Create a Team, a Collective Event Type and Book a Meeting", () =>
|
|||
await bookingPage.selectTimeSlot(eventTypePage);
|
||||
await bookingPage.addGuests(eventTypePage, { guests: ["test@example.com"] });
|
||||
await bookingPage.confirmBooking(eventTypePage);
|
||||
await bookingPage.goToPage("Back to bookings", eventTypePage);
|
||||
await bookingPage.goToPage(backToBookingsText, eventTypePage);
|
||||
await bookingPage.assertLabelWithCorrectTeamName(eventTypePage, teamName);
|
||||
await bookingPage.assertBookingWithCorrectTitleAndDescription(eventTypePage, {
|
||||
profileName: "testuser",
|
||||
|
|
Loading…
Reference in New Issue
Block a user