+5






![kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>](/assets/img/avatar_default.png)


Leo Giovanetti
GitHub
kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
Omar López
CarinaWolli
Hariom Balhara
Joe Au-Yeung
Syed Ali Shahbaz
Peer Richelsen
Udit Takkar
Carina Wollendorfer
Joe Au-Yeung
hexcowboy
sean-brydon
Alex van Andel
d55ffe8d9d
* First commit * Additional changes to meet designs * Fixing app details disconnect button App Store category filtering fixed * Further changes for the fix * Progress on various fronts * Fixing e2e tests * second try fixing e2e tests * Yet again trying to fix e2e tests * Missing action for non-credential flow * Adding missing Add button * Final tweaks and fixes * Missing button in empty screen * fix border radius * EmptyScreen for calendar * Dynamic installed app return page with highlights + other fixes * Removing unneeded code * App Store V2 Improvements over feat/v2-installed-apps (#4379) * Removing unneeded text * Fixing app details disconnect button and number of apps (#4305) * V2 Settings Shell - Add Teams Section & UI fixes (#4347) * Add teams to sidebar and fix UI * Clean up * V2 Multi-select (Team Select) (#4324) * --init * design improved * further fine tuning * more fixes * removed extra JSX tag * added story * NIT * revert to use of CheckedTeamSelect * Removes comments Co-authored-by: Peer Richelsen <peeroke@gmail.com> * fix: toggle alligment (#4361) * fix: add checked tranform for switch (#4357) * fixed input size on mobile, fixed settings (#4360) * fixing type errors * Mobile fixes * Tests fixes Co-authored-by: Syed Ali Shahbaz <52925846+alishaz-polymath@users.noreply.github.com> Co-authored-by: Peer Richelsen <peeroke@gmail.com> Co-authored-by: Udit Takkar <53316345+Udit-takkar@users.noreply.github.com> Co-authored-by: CarinaWolli <wollencarina@gmail.com> Co-authored-by: zomars <zomars@me.com> * Feat/team owner booking (#3999) * WIP: testing queries * feat: add badge * fix: get only id * refactor: get bookings query * WIP: display attendees added * fix: add type * Adds skeleton loader to workflows (#4402) * fix event types skeleton loader * fix margin in event types * fix skeleton loader in bookings * add skeleton loader for workflow list * add skeleton loader for editing page * fix border radius of skeleton loader * fix mobile view workflow list * add mobile view for skeleton list * make multi select full with in mobile view * mobile view for edit skeleton loader Co-authored-by: CarinaWolli <wollencarina@gmail.com> Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com> * V2 settings teams (Profil, Members, Appearance View) (#4350) * add team profile * first version for team members page * finish up design of member list item * fix dialog buttons * add missing seats and upgrading information * add v2 dialog for changing role * finish basic version of member's schedule * remove modalContainer * design fixes team profile page * show only team info to non admins * allow all member to check availabilities * make time available heading sticky * add dropdown for mobile view * create team appearance view * finish appearance page * use settings layout and add danger zone for member * add fallback logo * Add teams to sidebar and fix UI * add team invitations * Clean up * code clean up * add impersontation and disable autofocus on calendar * improve team info * refactor teaminvitelist code and fix leaving a team * add team pages to settings shell * add link to create new team * small fixes * clean up comments * V2 Multi-select (Team Select) (#4324) * --init * design improved * further fine tuning * more fixes * removed extra JSX tag * added story * NIT * revert to use of CheckedTeamSelect * Removes comments Co-authored-by: Peer Richelsen <peeroke@gmail.com> * fix: toggle alligment (#4361) * fix: add checked tranform for switch (#4357) * fixed input size on mobile, fixed settings (#4360) * fix image uploader button in safari * code clean up * fixing type errors * Moved v2 team components to features Adds deprecation notices * Update SettingsLayout.tsx * Migrated to features and build fixes Co-authored-by: CarinaWolli <wollencarina@gmail.com> Co-authored-by: Joe Au-Yeung <j.auyeung419@gmail.com> Co-authored-by: Syed Ali Shahbaz <52925846+alishaz-polymath@users.noreply.github.com> Co-authored-by: Peer Richelsen <peeroke@gmail.com> Co-authored-by: Udit Takkar <53316345+Udit-takkar@users.noreply.github.com> Co-authored-by: Joe Au-Yeung <65426560+joeauyeung@users.noreply.github.com> Co-authored-by: zomars <zomars@me.com> * add rainbowkit form to v2 event-types (#4349) Co-authored-by: Omar López <zomars@me.com> * v1.9.5 * Fix/daterangepicker css (#4418) * added styles from external stylesheet * fixed a border color * codacy improvements * more codacy fix * codacy why u be so dumb * dynamic import rainbow (only if installed) (#4409) * Tidyup app cards (#4428) * Moving API to trpc query Co-authored-by: Joe Au-Yeung <65426560+joeauyeung@users.noreply.github.com> Co-authored-by: Syed Ali Shahbaz <52925846+alishaz-polymath@users.noreply.github.com> Co-authored-by: Peer Richelsen <peeroke@gmail.com> Co-authored-by: Udit Takkar <53316345+Udit-takkar@users.noreply.github.com> Co-authored-by: CarinaWolli <wollencarina@gmail.com> Co-authored-by: zomars <zomars@me.com> Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com> Co-authored-by: Carina Wollendorfer <30310907+CarinaWolli@users.noreply.github.com> Co-authored-by: Joe Au-Yeung <j.auyeung419@gmail.com> Co-authored-by: hexcowboy <accounts@cowboy.dev> Co-authored-by: sean-brydon <55134778+sean-brydon@users.noreply.github.com> * Abstracting one level the redirectUrl for apps * Moving enum to a better/working place * Another try * Missing code * Correcting categories look in apps page * ui tweaks * Breadcrumb wrong font-weight * Toast is v1 component and copy updated * Fix TS error * Fix TS error * Update AppsLayout.tsx * Update InstalledAppsLayout.tsx * translations and disconnect button with icon * Reverting file * Test e2e fix on app-store * Missing testid in button * Fix to click categories that are visible * Going directly to category page as a patch * Fixing stripe e2e test * Disconnect is now empty with icon * Disabled stripe test for now as the navigation is completely changed Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com> Co-authored-by: Omar López <zomars@me.com> Co-authored-by: CarinaWolli <wollencarina@gmail.com> Co-authored-by: Hariom Balhara <hariombalhara@gmail.com> Co-authored-by: Joe Au-Yeung <65426560+joeauyeung@users.noreply.github.com> Co-authored-by: Syed Ali Shahbaz <52925846+alishaz-polymath@users.noreply.github.com> Co-authored-by: Peer Richelsen <peeroke@gmail.com> Co-authored-by: Udit Takkar <53316345+Udit-takkar@users.noreply.github.com> Co-authored-by: Carina Wollendorfer <30310907+CarinaWolli@users.noreply.github.com> Co-authored-by: Joe Au-Yeung <j.auyeung419@gmail.com> Co-authored-by: hexcowboy <accounts@cowboy.dev> Co-authored-by: sean-brydon <55134778+sean-brydon@users.noreply.github.com> Co-authored-by: Alex van Andel <me@alexvanandel.com>
85 lines
3.0 KiB
TypeScript
85 lines
3.0 KiB
TypeScript
import { expect } from "@playwright/test";
|
|
|
|
import { test } from "./lib/fixtures";
|
|
import { selectFirstAvailableTimeSlotNextMonth, todo } from "./lib/testUtils";
|
|
|
|
test.describe.configure({ mode: "parallel" });
|
|
|
|
const IS_STRIPE_ENABLED = !!(
|
|
process.env.STRIPE_CLIENT_ID &&
|
|
process.env.NEXT_PUBLIC_STRIPE_PUBLIC_KEY &&
|
|
process.env.STRIPE_PRIVATE_KEY
|
|
);
|
|
|
|
// TODO: No longer up to date, rewrite needed.
|
|
|
|
// eslint-disable-next-line playwright/no-skipped-test
|
|
test.skip();
|
|
|
|
test.describe("Stripe integration", () => {
|
|
// eslint-disable-next-line playwright/no-skipped-test
|
|
test.skip(!IS_STRIPE_ENABLED, "It should only run if Stripe is installed");
|
|
|
|
test.describe("Stripe integration dashboard", () => {
|
|
test("Can add Stripe integration", async ({ page, users }) => {
|
|
const user = await users.create();
|
|
await user.login();
|
|
await page.goto("/apps/installed");
|
|
|
|
await user.getPaymentCredential();
|
|
|
|
/** If Stripe is added correctly we should see the "Disconnect" button */
|
|
await expect(
|
|
page.locator(`li:has-text("Stripe") >> [data-testid="stripe_payment-integration-disconnect-button"]`)
|
|
).toContainText("");
|
|
|
|
// Cleanup
|
|
await users.deleteAll();
|
|
});
|
|
});
|
|
|
|
test("Can book a paid booking", async ({ page, users }) => {
|
|
const user = await users.create();
|
|
const eventType = user.eventTypes.find((e) => e.slug === "paid")!;
|
|
await user.login();
|
|
await page.goto("/apps/installed");
|
|
await user.getPaymentCredential();
|
|
|
|
await page.goto(`${user.username}/${eventType.slug}`);
|
|
await selectFirstAvailableTimeSlotNextMonth(page);
|
|
// --- fill form
|
|
await page.fill('[name="name"]', "Stripe Stripeson");
|
|
await page.fill('[name="email"]', "test@example.com");
|
|
|
|
await Promise.all([page.waitForNavigation({ url: "/payment/*" }), page.press('[name="email"]', "Enter")]);
|
|
|
|
const stripeFrame = page
|
|
.frameLocator('iframe[src^="https://js.stripe.com/v3/elements-inner-card-"]')
|
|
.first();
|
|
|
|
// Fill [placeholder="Card number"]
|
|
await stripeFrame.locator('[placeholder="Card number"]').fill("4242 4242 4242 4242");
|
|
// Fill [placeholder="MM / YY"]
|
|
await stripeFrame.locator('[placeholder="MM / YY"]').fill("12 / 24");
|
|
// Fill [placeholder="CVC"]
|
|
await stripeFrame.locator('[placeholder="CVC"]').fill("111");
|
|
// Fill [placeholder="ZIP"]
|
|
await stripeFrame.locator('[placeholder="ZIP"]').fill("11111");
|
|
// Click button:has-text("Pay now")
|
|
await page.click('button:has-text("Pay now")');
|
|
|
|
// Make sure we're navigated to the success page
|
|
await expect(page.locator("[data-testid=success-page]")).toBeVisible();
|
|
|
|
// Cleanup
|
|
await users.deleteAll();
|
|
});
|
|
|
|
todo("Pending payment booking should not be confirmed by default");
|
|
todo("Payment should confirm pending payment booking");
|
|
todo("Payment should trigger a BOOKING_PAID webhook");
|
|
todo("Paid booking should be able to be rescheduled");
|
|
todo("Paid booking should be able to be cancelled");
|
|
todo("Cancelled paid booking should be refunded");
|
|
});
|