Improve tests

This commit is contained in:
Alfonso Grillo
2023-01-30 18:23:31 +01:00
parent 739fe7a09a
commit 9eedb8fe79
3 changed files with 35 additions and 21 deletions
@@ -46,7 +46,7 @@ class MockNotificationSettingsService: NotificationSettingsServiceType, Observab
func updatePushRuleActions(for ruleId: String, enabled: Bool, actions: NotificationActions?, completion: ((Result<Void, Error>) -> Void)?) {
guard let ruleIndex = rules.firstIndex(where: { $0.ruleId == ruleId }) else {
completion?(.failure(NSError(domain: "fake", code: 0)))
completion?(.success(()))
return
}