mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-02 21:33:26 +00:00
Updated Screenshot Tests and fixed an issue with the MockMediaProvider (#554)
* updated the tests * updated ui tests * removed unused files * fixed a bug that prevented the image to be added in the avatar of the rooms from the mock, and improved some UI tests * swiftformat * fixed an issue where the room Id was not matching the real room id coming from the timelineController, also updated some tests, and added a test for the case where the RoomAvatar is available. * added some waitForExistence checks to allow the CI to find the UI elements * this should make the loading bar always match at the HStack size * code improvement for the tests * fix for the max frame of the loading screen * updated tests * regenerated and improved some tests * sonarcloud improvements * changelog
This commit is contained in:
@@ -119,7 +119,7 @@ class BugReportService: NSObject, BugReportServiceProtocol {
|
||||
if let progressListener {
|
||||
progressSubject
|
||||
.receive(on: DispatchQueue.main)
|
||||
.assign(to: \.value, on: progressListener.progressSubject)
|
||||
.weakAssign(to: \.value, on: progressListener.progressSubject)
|
||||
.store(in: &cancellables)
|
||||
(data, _) = try await session.data(for: request, delegate: self)
|
||||
} else {
|
||||
|
||||
@@ -19,7 +19,7 @@ import UIKit
|
||||
|
||||
struct MockMediaProvider: MediaProviderProtocol {
|
||||
func imageFromSource(_ source: MediaSourceProxy?, size: CGSize?) -> UIImage? {
|
||||
nil
|
||||
imageFromURL(source?.url, size: size)
|
||||
}
|
||||
|
||||
func loadImageFromSource(_ source: MediaSourceProxy, size: CGSize?) async -> Result<UIImage, MediaProviderError> {
|
||||
|
||||
@@ -19,7 +19,7 @@ import Foundation
|
||||
import MatrixRustSDK
|
||||
|
||||
struct MockRoomProxy: RoomProxyProtocol {
|
||||
let id = UUID().uuidString
|
||||
var id = UUID().uuidString
|
||||
let name: String? = nil
|
||||
let displayName: String?
|
||||
var topic: String?
|
||||
|
||||
Reference in New Issue
Block a user