diff --git a/Sources/NIOTestUtils/NIOHTTP1TestServer.swift b/Sources/NIOTestUtils/NIOHTTP1TestServer.swift index 08712e2f95b..091ac1b97e2 100644 --- a/Sources/NIOTestUtils/NIOHTTP1TestServer.swift +++ b/Sources/NIOTestUtils/NIOHTTP1TestServer.swift @@ -272,7 +272,8 @@ public final class NIOHTTP1TestServer { try channel.pipeline.syncOperations.addHandler(TransformerHandler()) _ = try channel.syncOptions!.setOption(.autoRead, value: true) } catch { - fatalError("Channel initialization failed with: \(error)") + print("Channel initialization failed with: \(error)") + channel.close(promise: nil) } }