Bundle ClientProxy & MediaProvider injections together in UserSession.

This commit is contained in:
Doug
2025-08-27 17:25:28 +01:00
committed by Doug
parent b34816e159
commit f67f826bb7
74 changed files with 315 additions and 499 deletions
@@ -16,8 +16,7 @@ class BlockedUsersScreenViewModelTests: XCTestCase {
let clientProxy = ClientProxyMock(.init(userID: RoomMemberProxyMock.mockMe.userID))
let viewModel = BlockedUsersScreenViewModel(hideProfiles: true,
clientProxy: clientProxy,
mediaProvider: MediaProviderMock(configuration: .init()),
userSession: UserSessionMock(.init(clientProxy: clientProxy)),
userIndicatorController: ServiceLocator.shared.userIndicatorController)
let deferred = deferFailure(viewModel.context.observe(\.viewState.blockedUsers), timeout: 1) { $0.contains { $0.displayName != nil } }
@@ -31,8 +30,7 @@ class BlockedUsersScreenViewModelTests: XCTestCase {
let clientProxy = ClientProxyMock(.init(userID: RoomMemberProxyMock.mockMe.userID))
let viewModel = BlockedUsersScreenViewModel(hideProfiles: false,
clientProxy: clientProxy,
mediaProvider: MediaProviderMock(configuration: .init()),
userSession: UserSessionMock(.init(clientProxy: clientProxy)),
userIndicatorController: ServiceLocator.shared.userIndicatorController)
let deferred = deferFulfillment(viewModel.context.observe(\.viewState.blockedUsers)) { $0.contains { $0.displayName != nil } }