Deflake verification playwright tests (#12669)
Turns out the sleep that got removed in https://github.com/matrix-org/matrix-react-sdk/pull/12667 was useful.
This commit is contained in:
parent
5eb5ea81d5
commit
736b083a79
2 changed files with 17 additions and 4 deletions
|
@ -50,11 +50,17 @@ test.describe("Device verification", () => {
|
|||
bootstrapSecretStorage: true,
|
||||
});
|
||||
aliceBotClient.setCredentials(credentials);
|
||||
const mxClientHandle = await aliceBotClient.prepareClient();
|
||||
|
||||
expectedBackupVersion = await mxClientHandle.evaluate(async (mxClient) => {
|
||||
return await mxClient.getCrypto()!.getActiveSessionBackupVersion();
|
||||
});
|
||||
// Backup is prepared in the background. Poll until it is ready.
|
||||
const botClientHandle = await aliceBotClient.prepareClient();
|
||||
await expect
|
||||
.poll(async () => {
|
||||
expectedBackupVersion = await botClientHandle.evaluate((cli) =>
|
||||
cli.getCrypto()!.getActiveSessionBackupVersion(),
|
||||
);
|
||||
return expectedBackupVersion;
|
||||
})
|
||||
.not.toBe(null);
|
||||
});
|
||||
|
||||
// Click the "Verify with another device" button, and have the bot client auto-accept it.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue