Skip to content

Commit 2edac1d

Browse files
authored
Deflake HTTP2ConnectionTests/testSimpleGetRequest (#851)
Motivation: testSimpleGetRequest asserts right after submitting the request for execution that no streams have been closed. While unlikely there's nothing to prevent this assertion from failing (and indeed it has failed): the request may have executed immediately and the stream closed before checking the delegate. Modifications: - Remove the assertion Result: Tests are less flaky
1 parent 64021b3 commit 2edac1d

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

Tests/AsyncHTTPClientTests/HTTP2ConnectionTests.swift

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,6 @@ class HTTP2ConnectionTests: XCTestCase {
115115

116116
http2Connection.executeRequest(requestBag)
117117

118-
XCTAssertEqual(delegate.hitStreamClosed, 0)
119118
var maybeResponse: HTTPClient.Response?
120119
XCTAssertNoThrow(maybeResponse = try requestBag.task.futureResult.wait())
121120
XCTAssertEqual(maybeResponse?.status, .ok)

0 commit comments

Comments
 (0)