Skip to content

Commit

Permalink
Hang on to the cancellable.
Browse files Browse the repository at this point in the history
  • Loading branch information
mbrandonw committed Jan 21, 2020
1 parent ab11015 commit 80693cc
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ class CounterTests: XCTestCase {

var nextAction: CounterViewAction!
let receivedCompletion = self.expectation(description: "receivedCompletion")
effects[0].sink(
let cancellable = effects[0].sink(
receiveCompletion: { _ in
receivedCompletion.fulfill()
},
Expand Down Expand Up @@ -138,7 +138,7 @@ class CounterTests: XCTestCase {

var nextAction: CounterViewAction!
let receivedCompletion = self.expectation(description: "receivedCompletion")
effects[0].sink(
let cancellable = effects[0].sink(
receiveCompletion: { _ in
receivedCompletion.fulfill()
},
Expand Down

0 comments on commit 80693cc

Please sign in to comment.