Fix preview tests/snapshots.

This commit is contained in:
Doug
2026-07-02 10:12:56 +01:00
committed by Doug
parent ace05b97d0
commit e3ac4a0b6c
15 changed files with 39 additions and 32 deletions
@@ -138,10 +138,13 @@ struct UserDetailsEditScreen_Previews: PreviewProvider, TestablePreview {
}
static func makeViewModel(canChangeProfile: Bool = true) -> UserDetailsEditScreenViewModel {
UserDetailsEditScreenViewModel(userSession: UserSessionMock(.init(clientProxy: ClientProxyMock(.init(userID: "@stefan:matrix.org",
canChangeAvatar: canChangeProfile,
canChangeDisplayName: canChangeProfile)))),
mediaUploadingPreprocessor: .init(appSettings: .volatile()),
userIndicatorController: UserIndicatorControllerMock())
let userSession = UserSessionMock(.init(clientProxy: ClientProxyMock(.init(userID: "@stefan:matrix.org",
displayName: "Stefan",
canChangeAvatar: canChangeProfile,
canChangeDisplayName: canChangeProfile))))
return UserDetailsEditScreenViewModel(userSession: userSession,
mediaUploadingPreprocessor: .init(appSettings: .volatile()),
userIndicatorController: UserIndicatorControllerMock())
}
}