Merge branch 't3chguy/prepare-playwright-testcontainers' of https://github.com/vector-im/element-web into t3chguy/playwright-testcontainers

# Conflicts:
#	playwright/e2e/register/register.spec.ts
pull/28860/head
Michael Telatynski 2025-01-06 17:29:29 +00:00
commit 69723c5b47
No known key found for this signature in database
GPG Key ID: A2B008A5F49F5D0D
4 changed files with 15 additions and 12 deletions

View File

@ -12,15 +12,6 @@ import { logIntoElement } from "./utils";
test.describe("Complete security", () => {
test.use({
displayName: "Jeff",
config: {
// The only thing that we really *need* (otherwise Element refuses to load) is a default homeserver.
// We point that to a guaranteed-invalid domain.
default_server_config: {
"m.homeserver": {
base_url: "https://server.invalid",
},
},
},
});
test("should go straight to the welcome screen if we have no signed device", async ({
@ -32,5 +23,5 @@ test.describe("Complete security", () => {
await expect(page.getByText("Welcome Jeff", { exact: true })).toBeVisible();
});
// see also "Verify device during login with SAS" in `verifiction.spec.ts`.
// see also "Verify device during login with SAS" in `verification.spec.ts`.
});

View File

@ -26,7 +26,7 @@ test.describe("Email Registration", async () => {
}),
});
test.beforeEach(async ({ page }) => {
test.beforeEach(async ({ homeserver, page }) => {
await page.goto("/#/register");
});

View File

@ -11,6 +11,17 @@ import { consentHomeserver } from "../../plugins/homeserver/synapse/consentHomes
test.describe("Registration", () => {
test.use(consentHomeserver);
test.use({
config: {
// The only thing that we really *need* (otherwise Element refuses to load) is a default homeserver.
// We point that to a guaranteed-invalid domain.
default_server_config: {
"m.homeserver": {
base_url: "https://server.invalid",
},
},
},
});
test.beforeEach(async ({ page }) => {
await page.goto("/#/register");

View File

@ -115,12 +115,13 @@ export const test = base.extend<Fixtures>({
await context.route(`http://localhost:8080/config.json*`, async (route) => {
const json = {
...CONFIG_JSON,
...config,
default_server_config: {
"m.homeserver": {
base_url: homeserver.baseUrl,
},
...config.default_server_config,
},
...config,
};
json["features"] = {
...json["features"],