Fix failing test
parent
4675a72e6b
commit
49e913865d
|
@ -140,57 +140,59 @@ mod test {
|
||||||
|
|
||||||
#[cfg(not(feature = "messages"))]
|
#[cfg(not(feature = "messages"))]
|
||||||
assert_eq!(
|
assert_eq!(
|
||||||
r#"{
|
serde_json::json!({
|
||||||
"!roomid:example.com": {
|
"!roomid:example.com": {
|
||||||
"room_id": "!roomid:example.com",
|
"room_id": "!roomid:example.com",
|
||||||
"room_name": {
|
"room_name": {
|
||||||
"name": null,
|
"name": null,
|
||||||
"canonical_alias": null,
|
"canonical_alias": null,
|
||||||
"aliases": [],
|
"aliases": [],
|
||||||
"heroes": [],
|
"heroes": [],
|
||||||
"joined_member_count": null,
|
"joined_member_count": null,
|
||||||
"invited_member_count": null
|
"invited_member_count": null
|
||||||
},
|
},
|
||||||
"own_user_id": "@example:example.com",
|
"own_user_id": "@example:example.com",
|
||||||
"creator": null,
|
"creator": null,
|
||||||
"members": {},
|
"members": {},
|
||||||
"typing_users": [],
|
"display_names": {},
|
||||||
"power_levels": null,
|
"typing_users": [],
|
||||||
"encrypted": null,
|
"power_levels": null,
|
||||||
"unread_highlight": null,
|
"encrypted": null,
|
||||||
"unread_notifications": null,
|
"unread_highlight": null,
|
||||||
"tombstone": null
|
"unread_notifications": null,
|
||||||
}
|
"tombstone": null
|
||||||
}"#,
|
}
|
||||||
serde_json::to_string_pretty(&joined_rooms).unwrap()
|
}),
|
||||||
|
serde_json::to_value(&joined_rooms).unwrap()
|
||||||
);
|
);
|
||||||
|
|
||||||
#[cfg(feature = "messages")]
|
#[cfg(feature = "messages")]
|
||||||
assert_eq!(
|
assert_eq!(
|
||||||
r#"{
|
serde_json::json!({
|
||||||
"!roomid:example.com": {
|
"!roomid:example.com": {
|
||||||
"room_id": "!roomid:example.com",
|
"room_id": "!roomid:example.com",
|
||||||
"room_name": {
|
"display_names": {},
|
||||||
"name": null,
|
"room_name": {
|
||||||
"canonical_alias": null,
|
"name": null,
|
||||||
"aliases": [],
|
"canonical_alias": null,
|
||||||
"heroes": [],
|
"aliases": [],
|
||||||
"joined_member_count": null,
|
"heroes": [],
|
||||||
"invited_member_count": null
|
"joined_member_count": null,
|
||||||
},
|
"invited_member_count": null
|
||||||
"own_user_id": "@example:example.com",
|
},
|
||||||
"creator": null,
|
"own_user_id": "@example:example.com",
|
||||||
"members": {},
|
"creator": null,
|
||||||
"messages": [],
|
"members": {},
|
||||||
"typing_users": [],
|
"messages": [],
|
||||||
"power_levels": null,
|
"typing_users": [],
|
||||||
"encrypted": null,
|
"power_levels": null,
|
||||||
"unread_highlight": null,
|
"encrypted": null,
|
||||||
"unread_notifications": null,
|
"unread_highlight": null,
|
||||||
"tombstone": null
|
"unread_notifications": null,
|
||||||
}
|
"tombstone": null
|
||||||
}"#,
|
}
|
||||||
serde_json::to_string_pretty(&joined_rooms).unwrap()
|
}),
|
||||||
|
serde_json::to_value(&joined_rooms).unwrap()
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue