mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-02 21:33:26 +00:00
Refactor UserSetting property wrapper to support Codable (#814)
* Add UserPreference property wrapper * Delete UserSetting property wrapper * Add PlistRepresentable support * Add more convenience inits * Add documentation * Add UTs * Fix flaky tests * Fix more flaky tests * Fix double optional problem in UserPreference * Refine UTs * Delete cache in UserPreference * Conform Date to PlistRepresentable
This commit is contained in:
@@ -111,7 +111,7 @@ class RoomDetailsScreenViewModelTests: XCTestCase {
|
||||
func testIgnoreFailure() async throws {
|
||||
let recipient = RoomMemberProxyMock.mockDan
|
||||
recipient.ignoreUserClosure = {
|
||||
try? await Task.sleep(for: .milliseconds(10))
|
||||
try? await Task.sleep(for: .milliseconds(100))
|
||||
return .failure(.ignoreUserFailed)
|
||||
}
|
||||
let mockedMembers: [RoomMemberProxyMock] = [.mockMe, recipient]
|
||||
@@ -132,7 +132,7 @@ class RoomDetailsScreenViewModelTests: XCTestCase {
|
||||
func testUnignoreSuccess() async throws {
|
||||
let recipient = RoomMemberProxyMock.mockIgnored
|
||||
recipient.unignoreUserClosure = {
|
||||
try? await Task.sleep(for: .milliseconds(10))
|
||||
try? await Task.sleep(for: .milliseconds(100))
|
||||
return .success(())
|
||||
}
|
||||
let mockedMembers: [RoomMemberProxyMock] = [.mockMe, recipient]
|
||||
|
||||
Reference in New Issue
Block a user