Skip to content

Commit

Permalink
Fix quotest
Browse files Browse the repository at this point in the history
  • Loading branch information
nvrWhere committed Nov 30, 2024
1 parent f059e78 commit 8213e61
Showing 1 changed file with 10 additions and 5 deletions.
15 changes: 10 additions & 5 deletions quotest/quotest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -887,11 +887,16 @@ TEST_IMPL(thread)
})
.unwrap()
.then(this, [this, thisTest](const RoomEvent& replyEvt) {
const auto rmReplyEvt = eventCast<const RoomMessageEvent>(&replyEvt);
const auto thread = targetRoom->threads()[rmReplyEvt->threadRootEventId()];
FINISH_TEST(thread.threadRootId == rmReplyEvt->threadRootEventId() &&
thread.latestEventId == rmReplyEvt->id() &&
thread.size == 2
replyEvt.switchOnType(
[&](const RoomMessageEvent& rmReplyEvt) {
const auto thread = targetRoom->threads()[rmReplyEvt.threadRootEventId()];
clog << thread.threadRootId.toStdString() << rmReplyEvt.threadRootEventId().toStdString() << thread.latestEventId.toStdString() << rmReplyEvt.id().toStdString() << thread.size;
FINISH_TEST(thread.threadRootId == rmReplyEvt.threadRootEventId() &&
thread.latestEventId == rmReplyEvt.id() &&
thread.size == 2
);
},
[this, thisTest](const RoomEvent&) { FAIL_TEST(); }
);
});
return false;
Expand Down

0 comments on commit 8213e61

Please sign in to comment.