Skip to content

Commit

Permalink
Fixing tests
Browse files Browse the repository at this point in the history
  • Loading branch information
ajaysubra committed Apr 10, 2024
1 parent 617aedd commit 352ded6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Tests/KlaviyoSwiftTests/APIRequestErrorHandlingTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ class APIRequestErrorHandlingTests: XCTestCase {
initialState.requestsInFlight = [request]
let store = TestStore(initialState: initialState, reducer: KlaviyoReducer())

environment.analytics.klaviyoAPI.send = { _, _ in .failure(.rateLimitError) }
environment.analytics.klaviyoAPI.send = { _, _ in .failure(.rateLimitError(nil)) }

_ = await store.send(.sendRequest)

Expand All @@ -286,7 +286,7 @@ class APIRequestErrorHandlingTests: XCTestCase {
initialState.requestsInFlight = [request]
let store = TestStore(initialState: initialState, reducer: KlaviyoReducer())

environment.analytics.klaviyoAPI.send = { _, _ in .failure(.rateLimitError) }
environment.analytics.klaviyoAPI.send = { _, _ in .failure(.rateLimitError(nil)) }

_ = await store.send(.sendRequest)

Expand All @@ -305,7 +305,7 @@ class APIRequestErrorHandlingTests: XCTestCase {
initialState.requestsInFlight = [request]
let store = TestStore(initialState: initialState, reducer: KlaviyoReducer())

environment.analytics.klaviyoAPI.send = { _ in .failure(.rateLimitError(20)) }
environment.analytics.klaviyoAPI.send = { _, _ in .failure(.rateLimitError(20)) }

_ = await store.send(.sendRequest)

Expand Down

0 comments on commit 352ded6

Please sign in to comment.