mirror of
https://github.com/element-hq/synapse.git
synced 2026-11-04 09:07:22 +00:00
Test reading server announcement history once the room is unconfigured
This commit is contained in:
1 file changed
+10
@@ -166,3 +166,13 @@ class ServerAnnouncementsHistoryTestCase(unittest.HomeserverTestCase):
|
||||
self.announcement_id,
|
||||
[event["event_id"] for event in body["messages"]["chunk"]],
|
||||
)
|
||||
|
||||
def test_messages_after_room_is_unconfigured(self) -> None:
|
||||
"""The reader can still paginate back to the announcement once the room
|
||||
is removed from the configuration."""
|
||||
self.hs.config.serverannouncements.rooms = []
|
||||
|
||||
body = self._get(f"/rooms/{self.room_id}/messages?dir=b")
|
||||
self.assertIn(
|
||||
self.announcement_id, [event["event_id"] for event in body["chunk"]]
|
||||
)
|
||||
Reference in new issue
Block a user