Skip to content

Commit 655daa8

Browse files
committed
Formatting
1 parent 920e64c commit 655daa8

File tree

6 files changed

+16
-13
lines changed

6 files changed

+16
-13
lines changed

Sources/GRPC/ConnectionManagerChannelProvider.swift

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -280,8 +280,9 @@ internal struct DefaultChannelProvider: ConnectionManagerChannelProvider {
280280

281281
#if canImport(Network)
282282
if #available(macOS 10.14, iOS 12.0, watchOS 6.0, tvOS 12.0, *),
283-
let configurator = self.nwParametersConfigurator,
284-
let transportServicesBootstrap = bootstrap as? NIOTSConnectionBootstrap {
283+
let configurator = self.nwParametersConfigurator,
284+
let transportServicesBootstrap = bootstrap as? NIOTSConnectionBootstrap
285+
{
285286
_ = transportServicesBootstrap.configureNWParameters(configurator)
286287
}
287288
#endif

Sources/GRPC/ConnectionPool/GRPCChannelPool.swift

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,12 @@ import Logging
1717
import NIOCore
1818
import NIOPosix
1919

20+
import struct Foundation.UUID
21+
2022
#if canImport(Network)
2123
import Network
2224
#endif
2325

24-
import struct Foundation.UUID
25-
2626
public enum GRPCChannelPool {
2727
/// Make a new ``GRPCChannel`` on which calls may be made to gRPC services.
2828
///
@@ -336,7 +336,7 @@ extension GRPCChannelPool.Configuration {
336336
private var _nwParametersConfigurator: (any Sendable)?
337337
}
338338
}
339-
#endif // canImport(Network)
339+
#endif // canImport(Network)
340340

341341
/// The ID of a connection in the connection pool.
342342
public struct GRPCConnectionID: Hashable, Sendable, CustomStringConvertible {

Sources/GRPC/Server.swift

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -129,8 +129,9 @@ public final class Server: @unchecked Sendable {
129129
}
130130

131131
if #available(macOS 10.14, iOS 12.0, watchOS 6.0, tvOS 12.0, *),
132-
let configurator = configuration.nwParametersConfigurator,
133-
let transportServicesBootstrap = bootstrap as? NIOTSListenerBootstrap {
132+
let configurator = configuration.nwParametersConfigurator,
133+
let transportServicesBootstrap = bootstrap as? NIOTSListenerBootstrap
134+
{
134135
_ = transportServicesBootstrap.configureNWParameters(configurator)
135136
}
136137
#endif // canImport(Network)

Tests/GRPCTests/ConnectionManagerTests.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,14 +20,14 @@ import NIOEmbedded
2020
import NIOHTTP2
2121
import XCTest
2222

23+
@testable import GRPC
24+
2325
#if canImport(Network)
2426
import NIOConcurrencyHelpers
2527
import NIOTransportServices
2628
import Network
2729
#endif
2830

29-
@testable import GRPC
30-
3131
class ConnectionManagerTests: GRPCTestCase {
3232
private let loop = EmbeddedEventLoop()
3333
private let recorder = RecordingConnectivityDelegate()

Tests/GRPCTests/ConnectionPool/GRPCChannelPoolTests.swift

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -646,7 +646,8 @@ final class GRPCChannelPoolTests: GRPCTestCase {
646646
#if canImport(Network)
647647
func testNWParametersConfigurator() throws {
648648
let counter = NIOLockedValueBox(0)
649-
self.setUpClientAndServer(withTLS: false, eventLoopGroupType: .transportServicesEventLoopGroup) { configuration in
649+
self.setUpClientAndServer(withTLS: false, eventLoopGroupType: .transportServicesEventLoopGroup)
650+
{ configuration in
650651
configuration.transportServices.nwParametersConfigurator = { _ in
651652
counter.withLockedValue { $0 += 1 }
652653
}
@@ -657,6 +658,6 @@ final class GRPCChannelPoolTests: GRPCTestCase {
657658

658659
XCTAssertEqual(1, counter.withLockedValue({ $0 }))
659660
}
660-
#endif // canImport(Network)
661+
#endif // canImport(Network)
661662
}
662663
#endif // canImport(NIOSSL)

Tests/GRPCTests/ServerTests.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,10 @@
1414
* limitations under the License.
1515
*/
1616

17+
import GRPC
18+
import NIOConcurrencyHelpers
1719
import NIOTransportServices
1820
import XCTest
19-
import NIOConcurrencyHelpers
20-
import GRPC
2121

2222
#if canImport(Network)
2323
import Network

0 commit comments

Comments
 (0)