Expose draft updates to iOS bridge
This commit is contained in:
@@ -1303,6 +1303,13 @@ mod tests {
|
||||
assert_eq!(pinned[0].text, "Hello from fake TDLib");
|
||||
assert_eq!(session.download_photo(100).unwrap().path, "/tmp/fake-photo.jpg");
|
||||
assert_eq!(session.download_voice(200).unwrap().path, "/tmp/fake-voice.ogg");
|
||||
session
|
||||
.set_draft(chats[0].id, "Draft from Rust test".to_string())
|
||||
.unwrap();
|
||||
assert!(session.poll_events().iter().any(|event| matches!(
|
||||
event,
|
||||
IosEvent::DraftChanged { draft } if draft.text == "Draft from Rust test"
|
||||
)));
|
||||
|
||||
let sent = session
|
||||
.send_message(chats[0].id, "Hi from Swift".to_string(), None)
|
||||
|
||||
Reference in New Issue
Block a user