Clean up chatbarcache

This commit is contained in:
Tobias Fella
2026-02-20 13:18:43 +01:00
parent 23c0bdb647
commit 0375ef99a5
5 changed files with 33 additions and 75 deletions

View File

@@ -90,7 +90,7 @@ void ActionsTest::testActions()
QFETCH(std::optional<QString>, resultText);
QFETCH(std::optional<Quotient::RoomMessageEvent::MsgType>, type);
auto cache = new ChatBarCache(this);
auto cache = new ChatBarCache(room);
cache->cache() += Block::CacheItem{.type = MessageComponentType::Text, .content = QTextDocumentFragment::fromMarkdown(command)};
auto result = ActionsModel::handleAction(room, cache);
QCOMPARE(resultText, std::get<std::optional<QString>>(result));