diff --git a/playwright/e2e/crypto/migration.spec.ts b/playwright/e2e/crypto/migration.spec.ts index 86072fccc0..191568c29c 100644 --- a/playwright/e2e/crypto/migration.spec.ts +++ b/playwright/e2e/crypto/migration.spec.ts @@ -8,9 +8,13 @@ Please see LICENSE files in the repository root for full details. import path from "path"; import { readFile } from "node:fs/promises"; +import { dirname } from "node:path"; +import { fileURLToPath } from "node:url"; import { expect, test } from "../../element-web-test"; +const __dirname = dirname(fileURLToPath(import.meta.url)); + test.describe("migration", { tag: "@no-webkit" }, function () { test.use({ displayName: "Alice", diff --git a/playwright/plugins/oauth_server/index.ts b/playwright/plugins/oauth_server/index.ts index 446426a9c1..16aad2f027 100644 --- a/playwright/plugins/oauth_server/index.ts +++ b/playwright/plugins/oauth_server/index.ts @@ -11,6 +11,10 @@ import express from "express"; import { type AddressInfo } from "net"; import { type TestInfo } from "@playwright/test"; import { randB64Bytes } from "@element-hq/element-web-playwright-common/lib/utils/rand.js"; +import { dirname } from "node:path"; +import { fileURLToPath } from "node:url"; + +const __dirname = dirname(fileURLToPath(import.meta.url)); export class OAuthServer { private server?: http.Server;