Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add ability to pause/resume websocket without dumping subscriptions #1335

Merged
merged 7 commits into from
Aug 6, 2020
Prev Previous commit
Next Next commit
Don't cancel the subscription until after we've waited for it 🤦‍♀️ 🤦‍♀️
  • Loading branch information
designatednerd committed Aug 4, 2020
commit 4eb1f2a6a1026ddd9728dfa2a13a71908bcaf44f
6 changes: 3 additions & 3 deletions Tests/ApolloWebsocketTests/StarWarsSubscriptionTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -471,10 +471,10 @@ class StarWarsSubscriptionTests: XCTestCase {
// Now that we've reconnected, this should go through to the same subscription.
sendReview()

// Cancel subscription so it doesn't keep receiving from other tests.
sub.cancel()

self.wait(for: [subscriptionExpectation], timeout: 10)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
self.wait(for: [subscriptionExpectation], timeout: 10)
wait(for: [subscriptionExpectation], timeout: 10)


// Cancel subscription so it doesn't keep receiving from other tests.
sub.cancel()
}
}

Expand Down