Close incoming Element call toast when viewing the call lobby (#9375)
This commit is contained in:
parent
6b1ee13c28
commit
4ff9681408
2 changed files with 26 additions and 0 deletions
|
@ -155,4 +155,18 @@ describe("IncomingCallEvent", () => {
|
|||
|
||||
defaultDispatcher.unregister(dispatcherRef);
|
||||
});
|
||||
|
||||
it("closes toast when the call lobby is viewed", async () => {
|
||||
renderToast();
|
||||
|
||||
defaultDispatcher.dispatch({
|
||||
action: Action.ViewRoom,
|
||||
room_id: room.roomId,
|
||||
view_call: true,
|
||||
});
|
||||
|
||||
await waitFor(() => expect(toastStore.dismissToast).toHaveBeenCalledWith(
|
||||
getIncomingCallToastKey(call.event.getStateKey()!),
|
||||
));
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue