mirror of
https://github.com/signalapp/Signal-Desktop.git
synced 2026-04-22 17:38:10 +01:00
Enables ContextIsolation
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
// SPDX-License-Identifier: AGPL-3.0-only
|
||||
/* eslint-disable no-await-in-loop, no-console */
|
||||
|
||||
import type { PrimaryDevice } from '@signalapp/mock-server';
|
||||
import { StorageState } from '@signalapp/mock-server';
|
||||
|
||||
import type { App } from './fixtures';
|
||||
@@ -23,6 +24,7 @@ void (async () => {
|
||||
const { phone, server } = bootstrap;
|
||||
|
||||
let state = StorageState.getEmpty();
|
||||
let lastContact: PrimaryDevice | undefined;
|
||||
for (const [i, profileName] of contactNames.entries()) {
|
||||
const contact = await server.createPrimaryDevice({
|
||||
profileName,
|
||||
@@ -39,6 +41,10 @@ void (async () => {
|
||||
if (i >= contactNames.length - 4) {
|
||||
state = state.pin(contact);
|
||||
}
|
||||
|
||||
if (i === contactNames.length - 1) {
|
||||
lastContact = contact;
|
||||
}
|
||||
}
|
||||
|
||||
await phone.setStorageState(state);
|
||||
@@ -52,8 +58,7 @@ void (async () => {
|
||||
const leftPane = window.locator('.left-pane-wrapper');
|
||||
|
||||
const item = leftPane.locator(
|
||||
'_react=BaseConversationListItem' +
|
||||
`[title = ${JSON.stringify(contactNames[contactNames.length - 1])}]`
|
||||
`[data-testid="${lastContact?.toContact().uuid}"]`
|
||||
);
|
||||
await item.waitFor();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user