mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-04 01:20:12 +00:00
Reorder the TimelineController send methods
This commit is contained in:
committed by
Stefan Ceriu
parent
cedb2936d0
commit
a4c0b7f91c
+15
-13
@@ -108,19 +108,6 @@ class MockTimelineController: TimelineControllerProtocol {
|
||||
func processItemAppearance(_ itemID: TimelineItemIdentifier) async { }
|
||||
|
||||
func processItemDisappearance(_ itemID: TimelineItemIdentifier) async { }
|
||||
|
||||
func sendMessage(_ message: String,
|
||||
html: String?,
|
||||
inReplyToEventID: String?,
|
||||
intentionalMentions: IntentionalMentions) async { }
|
||||
|
||||
func sendVoiceMessage(url: URL, audioInfo: AudioInfo, waveform: [UInt16]) async -> Result<Void, TimelineProxyError> {
|
||||
if let timelineProxy {
|
||||
return await timelineProxy.sendVoiceMessage(url: url, audioInfo: audioInfo, waveform: waveform) { _ in }
|
||||
}
|
||||
|
||||
return .success(())
|
||||
}
|
||||
|
||||
func toggleReaction(_ reaction: String, to eventID: TimelineItemIdentifier.EventOrTransactionID) async { }
|
||||
|
||||
@@ -161,6 +148,21 @@ class MockTimelineController: TimelineControllerProtocol {
|
||||
timelineItemsTimestamp[itemID] ?? .now
|
||||
}
|
||||
|
||||
// MARK: - Sending
|
||||
|
||||
func sendMessage(_ message: String,
|
||||
html: String?,
|
||||
inReplyToEventID: String?,
|
||||
intentionalMentions: IntentionalMentions) async { }
|
||||
|
||||
func sendVoiceMessage(url: URL, audioInfo: AudioInfo, waveform: [UInt16]) async -> Result<Void, TimelineProxyError> {
|
||||
if let timelineProxy {
|
||||
return await timelineProxy.sendVoiceMessage(url: url, audioInfo: audioInfo, waveform: waveform) { _ in }
|
||||
}
|
||||
|
||||
return .success(())
|
||||
}
|
||||
|
||||
// MARK: - UI Test signalling
|
||||
|
||||
/// The cancellable used for UI Tests signalling.
|
||||
|
||||
Reference in New Issue
Block a user