-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'develop' of https://github.com/vector-im/element-web in…
…to t3chguy/msc3967-cleanup # Conflicts: # src/CreateCrossSigning.ts # src/stores/InitialCryptoSetupStore.ts
- Loading branch information
Showing
17 changed files
with
187 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,6 +9,8 @@ Please see LICENSE files in the repository root for full details. | |
import { type Page } from "@playwright/test"; | ||
|
||
import { test, expect } from "../../element-web-test"; | ||
import { test as masTest, registerAccountMas } from "../oidc"; | ||
import { isDendrite } from "../../plugins/homeserver/dendrite"; | ||
|
||
async function expectBackupVersionToBe(page: Page, version: string) { | ||
await expect(page.locator(".mx_SecureBackupPanel_statusList tr:nth-child(5) td")).toHaveText( | ||
|
@@ -18,6 +20,32 @@ async function expectBackupVersionToBe(page: Page, version: string) { | |
await expect(page.locator(".mx_SecureBackupPanel_statusList tr:nth-child(6) td")).toHaveText(version); | ||
} | ||
|
||
masTest.describe("Encryption state after registration", () => { | ||
masTest.skip(isDendrite, "does not yet support MAS"); | ||
|
||
masTest("Key backup is enabled by default", async ({ page, mailhog, app }) => { | ||
await page.goto("/#/login"); | ||
await page.getByRole("button", { name: "Continue" }).click(); | ||
await registerAccountMas(page, mailhog.api, "alice", "[email protected]", "Pa$sW0rD!"); | ||
|
||
await app.settings.openUserSettings("Security & Privacy"); | ||
expect(page.getByText("This session is backing up your keys.")).toBeVisible(); | ||
}); | ||
|
||
masTest("user is prompted to set up recovery", async ({ page, mailhog, app }) => { | ||
await page.goto("/#/login"); | ||
await page.getByRole("button", { name: "Continue" }).click(); | ||
await registerAccountMas(page, mailhog.api, "alice", "[email protected]", "Pa$sW0rD!"); | ||
|
||
await page.getByRole("button", { name: "Add room" }).click(); | ||
await page.getByRole("menuitem", { name: "New room" }).click(); | ||
await page.getByRole("textbox", { name: "Name" }).fill("test room"); | ||
await page.getByRole("button", { name: "Create room" }).click(); | ||
|
||
await expect(page.getByRole("heading", { name: "Set up recovery" })).toBeVisible(); | ||
}); | ||
}); | ||
|
||
test.describe("Backups", () => { | ||
test.use({ | ||
displayName: "Hanako", | ||
|
File renamed without changes.
Binary file added
BIN
+34.4 KB
...settings-tab/message-layout-panel.spec.ts/message-layout-panel-bubble-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+34.4 KB
...settings-tab/message-layout-panel.spec.ts/message-layout-panel-modern-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
/* | ||
Copyright 2024 New Vector Ltd. | ||
SPDX-License-Identifier: AGPL-3.0-only OR GPL-3.0-only | ||
Please see LICENSE files in the repository root for full details. | ||
*/ | ||
|
||
import React from "react"; | ||
import { render, screen } from "jest-matrix-react"; | ||
|
||
import ToastContainer from "../../../src/components/structures/ToastContainer"; | ||
import { Kind, showToast } from "../../../src/toasts/SetupEncryptionToast"; | ||
|
||
describe("SetupEncryptionToast", () => { | ||
beforeEach(() => { | ||
render(<ToastContainer />); | ||
}); | ||
|
||
it("should render the se up recovery toast", async () => { | ||
showToast(Kind.SET_UP_RECOVERY); | ||
|
||
await expect(screen.findByText("Set up recovery")).resolves.toBeInTheDocument(); | ||
}); | ||
}); |
Oops, something went wrong.