From 6784d071a672f59dccedd63434ddcd4863129c97 Mon Sep 17 00:00:00 2001 From: Florian Duros Date: Wed, 26 Mar 2025 23:53:16 +0100 Subject: [PATCH] test(e2e dehydrated device): use Encryption tab instead of Security & Privacy tab (#29593) --- playwright/e2e/crypto/dehydration.spec.ts | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/playwright/e2e/crypto/dehydration.spec.ts b/playwright/e2e/crypto/dehydration.spec.ts index 89ee854c91..2f545b8d14 100644 --- a/playwright/e2e/crypto/dehydration.spec.ts +++ b/playwright/e2e/crypto/dehydration.spec.ts @@ -27,16 +27,22 @@ test.use({ test.describe("Dehydration", () => { test.skip(isDendrite, "does not yet support dehydration v2"); - test("'Set up secure backup' creates dehydrated device", async ({ page, user, app }, workerInfo) => { - // Create a backup (which will create SSSS, and dehydrated device) + test("Verify device and reset creates dehydrated device", async ({ page, user, credentials, app }, workerInfo) => { + // Verify the device by resetting the key (which will create SSSS, and dehydrated device) const securityTab = await app.settings.openUserSettings("Security & Privacy"); - - await expect(securityTab.getByRole("heading", { name: "Secure Backup" })).toBeVisible(); await expect(securityTab.getByText("Offline device enabled")).not.toBeVisible(); - await securityTab.getByRole("button", { name: "Set up", exact: true }).click(); - await completeCreateSecretStorageDialog(page); + await app.closeDialog(); + + // Verify the device by resetting the key + const settings = await app.settings.openUserSettings("Encryption"); + await settings.getByRole("button", { name: "Verify this device" }).click(); + await page.getByRole("button", { name: "Proceed with reset" }).click(); + await page.getByRole("button", { name: "Continue" }).click(); + await page.getByRole("button", { name: "Copy" }).click(); + await page.getByRole("button", { name: "Continue" }).click(); + await page.getByRole("button", { name: "Done" }).click(); await expectDehydratedDeviceEnabled(app);