Allow dismissing 'Key storage out of sync' temporarily (#31455)

This commit is contained in:
Andy Balaam
2026-01-26 10:46:40 +00:00
committed by GitHub
parent 828c4a47a4
commit 0947517746
6 changed files with 69 additions and 9 deletions

View File

@@ -189,6 +189,17 @@ describe("SetupEncryptionToast", () => {
props: { initialEncryptionState: "change_recovery_key" },
});
});
it("should dismiss the toast when the close button is clicked", async () => {
jest.spyOn(DeviceListener.sharedInstance(), "dismissEncryptionSetup");
act(() => showToast("key_storage_out_of_sync"));
const user = userEvent.setup();
await user.click(await screen.findByRole("button", { name: "Close" }));
expect(DeviceListener.sharedInstance().dismissEncryptionSetup).toHaveBeenCalled();
});
});
describe("Turn on key storage", () => {