fix tests

This commit is contained in:
fkwp
2026-04-09 18:54:15 +02:00
parent 03237b7a43
commit b2cc1781e5
2 changed files with 6 additions and 0 deletions

View File

@@ -109,6 +109,9 @@ function createInCallView(): RenderResult & {
getDeviceId: () => localRtcMember.deviceId,
getRoom: (rId) => (rId === roomId ? room : null),
getDomain: () => "example.com",
getAccessToken: () => "mock-access-token",
baseUrl: "https://matrix.example.com",
getOpenIdToken: vi.fn(),
} as Partial<MatrixClient> as MatrixClient;
const room = mockMatrixRoom({
relations: {

View File

@@ -63,6 +63,9 @@ export function getBasicRTCSession(
getDeviceId: () => localRtcMember.deviceId,
getSyncState: () => SyncState.Syncing,
getDomain: () => null,
getAccessToken: () => "mock-access-token",
baseUrl: "https://matrix.example.com",
getOpenIdToken: vitest.fn(),
sendEvent: vitest.fn().mockResolvedValue({ event_id: "$fake:event" }),
redactEvent: vitest.fn().mockResolvedValue({ event_id: "$fake:event" }),
decryptEventIfNeeded: vitest.fn().mockResolvedValue(undefined),