From 221b1d88f59b466f183e9b7575518203118af331 Mon Sep 17 00:00:00 2001 From: Adam Fowler Date: Mon, 20 Nov 2023 13:05:04 +0000 Subject: [PATCH] More Sendable conformance --- Sources/HummingbirdXCT/HBXCTApplication.swift | 2 +- Sources/HummingbirdXCT/TestHelpers.swift | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Sources/HummingbirdXCT/HBXCTApplication.swift b/Sources/HummingbirdXCT/HBXCTApplication.swift index 27c79734f..24be9ed15 100644 --- a/Sources/HummingbirdXCT/HBXCTApplication.swift +++ b/Sources/HummingbirdXCT/HBXCTApplication.swift @@ -18,7 +18,7 @@ import NIOHTTP1 import ServiceLifecycle /// Response structure returned by XCT testing framework -public struct HBXCTResponse { +public struct HBXCTResponse: Sendable { /// response status public let status: HTTPResponseStatus /// response headers diff --git a/Sources/HummingbirdXCT/TestHelpers.swift b/Sources/HummingbirdXCT/TestHelpers.swift index 8b4166d24..f1c4b085d 100644 --- a/Sources/HummingbirdXCT/TestHelpers.swift +++ b/Sources/HummingbirdXCT/TestHelpers.swift @@ -22,7 +22,7 @@ public struct TimeoutError: Error {} /// - timeout: Amount of time allowed for the task to run /// - process: Task to run /// - Returns: Result of task -public func withTimeout(timeout: Duration, _ process: @escaping @Sendable () async throws -> T) async throws -> T { +public func withTimeout(timeout: Duration, _ process: @escaping @Sendable () async throws -> T) async throws -> T { return try await withThrowingTaskGroup(of: T.self) { group in group.addTask { try await process()