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

use 3 EventLoops for tests #177

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Tests/AsyncHTTPClientTests/HTTPClientTestUtils.swift
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ enum TemporaryFileHelpers {
}

internal final class HTTPBin {
let group = MultiThreadedEventLoopGroup(numberOfThreads: 1)
let group = MultiThreadedEventLoopGroup(numberOfThreads: 3)
let serverChannel: Channel
let isShutdown: NIOAtomic<Bool> = .makeAtomic(value: false)
var connections: NIOAtomic<Int>
Expand Down Expand Up @@ -627,7 +627,7 @@ final class CountActiveConnectionsHandler: ChannelInboundHandler {
}

internal class HttpBinForSSLUncleanShutdown {
let group = MultiThreadedEventLoopGroup(numberOfThreads: 1)
let group = MultiThreadedEventLoopGroup(numberOfThreads: 3)
let serverChannel: Channel

var port: Int {
Expand Down
4 changes: 2 additions & 2 deletions Tests/AsyncHTTPClientTests/HTTPClientTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ class HTTPClientTests: XCTestCase {
XCTAssertNil(self.defaultClient)
XCTAssertNil(self.backgroundLogStore)

self.clientGroup = getDefaultEventLoopGroup(numberOfThreads: 1)
self.serverGroup = MultiThreadedEventLoopGroup(numberOfThreads: 1)
self.clientGroup = getDefaultEventLoopGroup(numberOfThreads: 3)
self.serverGroup = MultiThreadedEventLoopGroup(numberOfThreads: 3)
self.defaultHTTPBin = HTTPBin()
self.backgroundLogStore = CollectEverythingLogHandler.LogStore()
var backgroundLogger = Logger(label: "\(#function)", factory: { _ in
Expand Down