Use mapped types around account data events (#28752)

* Use mapped types around account data events

---------

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
This commit is contained in:
Michael Telatynski
2024-12-19 22:53:51 +00:00
committed by GitHub
parent baaed75c4b
commit be181d2c79
25 changed files with 152 additions and 71 deletions

View File

@@ -6,7 +6,14 @@ SPDX-License-Identifier: AGPL-3.0-only OR GPL-3.0-only
Please see LICENSE files in the repository root for full details.
*/
import { MatrixEvent, NotificationCountType, Room, MatrixClient, ReceiptType } from "matrix-js-sdk/src/matrix";
import {
MatrixEvent,
NotificationCountType,
Room,
MatrixClient,
ReceiptType,
AccountDataEvents,
} from "matrix-js-sdk/src/matrix";
import { Mocked, mocked } from "jest-mock";
import {
@@ -32,7 +39,7 @@ jest.mock("../../../src/settings/SettingsStore");
describe("notifications", () => {
let accountDataStore: Record<string, MatrixEvent> = {};
let mockClient: Mocked<MatrixClient>;
let accountDataEventKey: string;
let accountDataEventKey: keyof AccountDataEvents;
beforeEach(() => {
jest.clearAllMocks();