mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-02 21:33:26 +00:00
SDK Bump + Back pagination state listener (#1274)
* backPagination improved * sdk bump * removed unused line * Update ElementX/Sources/Services/Timeline/TimelineController/RoomTimelineController.swift Co-authored-by: Doug <6060466+pixlwave@users.noreply.github.com> * cancelling the TaskHandle on deallocation --------- Co-authored-by: Doug <6060466+pixlwave@users.noreply.github.com>
This commit is contained in:
@@ -1075,6 +1075,20 @@ class RoomProxyMock: RoomProxyProtocol {
|
||||
}
|
||||
}
|
||||
}
|
||||
class RoomTimelineProviderMock: RoomTimelineProviderProtocol {
|
||||
var updatePublisher: AnyPublisher<TimelineProviderUpdate, Never> {
|
||||
get { return underlyingUpdatePublisher }
|
||||
set(value) { underlyingUpdatePublisher = value }
|
||||
}
|
||||
var underlyingUpdatePublisher: AnyPublisher<TimelineProviderUpdate, Never>!
|
||||
var itemProxies: [TimelineItemProxy] = []
|
||||
var backPaginationState: BackPaginationStatus {
|
||||
get { return underlyingBackPaginationState }
|
||||
set(value) { underlyingBackPaginationState = value }
|
||||
}
|
||||
var underlyingBackPaginationState: BackPaginationStatus!
|
||||
|
||||
}
|
||||
class SessionVerificationControllerProxyMock: SessionVerificationControllerProxyProtocol {
|
||||
var callbacks: PassthroughSubject<SessionVerificationControllerProxyCallback, Never> {
|
||||
get { return underlyingCallbacks }
|
||||
|
||||
@@ -651,31 +651,6 @@ class SDKClientMock: SDKClientProtocol {
|
||||
setPusherIdentifiersKindAppDisplayNameDeviceDisplayNameProfileTagLangReceivedInvocations.append((identifiers: identifiers, kind: kind, appDisplayName: appDisplayName, deviceDisplayName: deviceDisplayName, profileTag: profileTag, lang: lang))
|
||||
try setPusherIdentifiersKindAppDisplayNameDeviceDisplayNameProfileTagLangClosure?(`identifiers`, `kind`, `appDisplayName`, `deviceDisplayName`, `profileTag`, `lang`)
|
||||
}
|
||||
//MARK: - `slidingSync`
|
||||
|
||||
public var slidingSyncIdThrowableError: Error?
|
||||
public var slidingSyncIdCallsCount = 0
|
||||
public var slidingSyncIdCalled: Bool {
|
||||
return slidingSyncIdCallsCount > 0
|
||||
}
|
||||
public var slidingSyncIdReceivedId: String?
|
||||
public var slidingSyncIdReceivedInvocations: [String] = []
|
||||
public var slidingSyncIdReturnValue: SlidingSyncBuilder!
|
||||
public var slidingSyncIdClosure: ((String) throws -> SlidingSyncBuilder)?
|
||||
|
||||
public func `slidingSync`(`id`: String) throws -> SlidingSyncBuilder {
|
||||
if let error = slidingSyncIdThrowableError {
|
||||
throw error
|
||||
}
|
||||
slidingSyncIdCallsCount += 1
|
||||
slidingSyncIdReceivedId = id
|
||||
slidingSyncIdReceivedInvocations.append(`id`)
|
||||
if let slidingSyncIdClosure = slidingSyncIdClosure {
|
||||
return try slidingSyncIdClosure(`id`)
|
||||
} else {
|
||||
return slidingSyncIdReturnValue
|
||||
}
|
||||
}
|
||||
//MARK: - `unignoreUser`
|
||||
|
||||
public var unignoreUserUserIdThrowableError: Error?
|
||||
|
||||
Reference in New Issue
Block a user