Update the SDK.

This commit is contained in:
Doug
2024-08-29 14:39:49 +01:00
committed by Stefan Ceriu
parent 4925884f6c
commit 342ad57ce7
8 changed files with 37 additions and 117 deletions
@@ -13854,8 +13854,8 @@ class TimelineProxyMock: TimelineProxyProtocol {
var toggleReactionToCalled: Bool {
return toggleReactionToCallsCount > 0
}
var toggleReactionToReceivedArguments: (reaction: String, eventID: String)?
var toggleReactionToReceivedInvocations: [(reaction: String, eventID: String)] = []
var toggleReactionToReceivedArguments: (reaction: String, itemID: TimelineItemIdentifier)?
var toggleReactionToReceivedInvocations: [(reaction: String, itemID: TimelineItemIdentifier)] = []
var toggleReactionToUnderlyingReturnValue: Result<Void, TimelineProxyError>!
var toggleReactionToReturnValue: Result<Void, TimelineProxyError>! {
@@ -13881,16 +13881,16 @@ class TimelineProxyMock: TimelineProxyProtocol {
}
}
}
var toggleReactionToClosure: ((String, String) async -> Result<Void, TimelineProxyError>)?
var toggleReactionToClosure: ((String, TimelineItemIdentifier) async -> Result<Void, TimelineProxyError>)?
func toggleReaction(_ reaction: String, to eventID: String) async -> Result<Void, TimelineProxyError> {
func toggleReaction(_ reaction: String, to itemID: TimelineItemIdentifier) async -> Result<Void, TimelineProxyError> {
toggleReactionToCallsCount += 1
toggleReactionToReceivedArguments = (reaction: reaction, eventID: eventID)
toggleReactionToReceivedArguments = (reaction: reaction, itemID: itemID)
DispatchQueue.main.async {
self.toggleReactionToReceivedInvocations.append((reaction: reaction, eventID: eventID))
self.toggleReactionToReceivedInvocations.append((reaction: reaction, itemID: itemID))
}
if let toggleReactionToClosure = toggleReactionToClosure {
return await toggleReactionToClosure(reaction, eventID)
return await toggleReactionToClosure(reaction, itemID)
} else {
return toggleReactionToReturnValue
}