From 6d2f7876232da37196aa6e405f4abc0e5c8ac5b2 Mon Sep 17 00:00:00 2001 From: Benjamin Bouvier Date: Mon, 16 Feb 2026 14:31:46 +0100 Subject: [PATCH] test(sync_builder): make add_account_data accept impl Into> Change JoinedRoomBuilder::add_account_data() to accept any type that implements Into>, preparing for migration away from RoomAccountDataTestEvent enum. --- testing/matrix-sdk-test/src/sync_builder/joined_room.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/testing/matrix-sdk-test/src/sync_builder/joined_room.rs b/testing/matrix-sdk-test/src/sync_builder/joined_room.rs index a1aa27d0a..65d7f04bc 100644 --- a/testing/matrix-sdk-test/src/sync_builder/joined_room.rs +++ b/testing/matrix-sdk-test/src/sync_builder/joined_room.rs @@ -9,7 +9,7 @@ use ruma::{ }; use serde_json::{Value as JsonValue, from_value as from_json_value}; -use super::{RoomAccountDataTestEvent, StateMutExt}; +use super::StateMutExt; use crate::{DEFAULT_TEST_ROOM_ID, event_factory::EventBuilder}; #[derive(Debug, Clone)] @@ -108,7 +108,7 @@ impl JoinedRoomBuilder { } /// Add room account data. - pub fn add_account_data(mut self, event: RoomAccountDataTestEvent) -> Self { + pub fn add_account_data(mut self, event: impl Into>) -> Self { self.inner.account_data.events.push(event.into()); self }