From 053c94b60e076c63315d8083bf8d55987053d8e2 Mon Sep 17 00:00:00 2001 From: Danila Fedorin Date: Fri, 6 Aug 2021 11:02:41 -0700 Subject: [PATCH] Stop passing room to tiles in tests --- src/domain/session/room/timeline/ReactionsViewModel.js | 2 +- src/domain/session/room/timeline/tiles/GapTile.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/domain/session/room/timeline/ReactionsViewModel.js b/src/domain/session/room/timeline/ReactionsViewModel.js index 51226775..65ad391f 100644 --- a/src/domain/session/room/timeline/ReactionsViewModel.js +++ b/src/domain/session/room/timeline/ReactionsViewModel.js @@ -222,7 +222,7 @@ export function tests() { }; const tiles = new MappedList(timeline.entries, entry => { if (entry.eventType === "m.room.message") { - return new BaseMessageTile({entry, room, timeline, platform: {logger}}); + return new BaseMessageTile({entry, roomVM: {room}, timeline, platform: {logger}}); } return null; }, (tile, params, entry) => tile?.updateEntry(entry, params)); diff --git a/src/domain/session/room/timeline/tiles/GapTile.js b/src/domain/session/room/timeline/tiles/GapTile.js index 1e227876..32d632bf 100644 --- a/src/domain/session/room/timeline/tiles/GapTile.js +++ b/src/domain/session/room/timeline/tiles/GapTile.js @@ -91,11 +91,11 @@ export function tests() { tile.updateEntry(newEntry); } }; - const tile = new GapTile({entry: new FragmentBoundaryEntry(fragment, true), room}); + const tile = new GapTile({entry: new FragmentBoundaryEntry(fragment, true), roomVM: {room}}); await tile.fill(); await tile.fill(); await tile.fill(); assert.equal(currentToken, 8); } } -} \ No newline at end of file +}