diff --git a/Tests/HummingbirdCoreTests/CoreTests.swift b/Tests/HummingbirdCoreTests/CoreTests.swift index 9ab463a3..e2e2ffdd 100644 --- a/Tests/HummingbirdCoreTests/CoreTests.swift +++ b/Tests/HummingbirdCoreTests/CoreTests.swift @@ -24,7 +24,7 @@ import NIOPosix import ServiceLifecycle import XCTest -class HummingBirdCoreTests: XCTestCase { +final class HummingBirdCoreTests: XCTestCase { static let eventLoopGroup: EventLoopGroup = { #if os(iOS) NIOTSEventLoopGroup.singleton diff --git a/Tests/HummingbirdCoreTests/HTTP2Tests.swift b/Tests/HummingbirdCoreTests/HTTP2Tests.swift index 33e051c1..ff9e30a5 100644 --- a/Tests/HummingbirdCoreTests/HTTP2Tests.swift +++ b/Tests/HummingbirdCoreTests/HTTP2Tests.swift @@ -24,7 +24,7 @@ import NIOSSL import NIOTransportServices import XCTest -class HummingBirdHTTP2Tests: XCTestCase { +final class HummingBirdHTTP2Tests: XCTestCase { func testConnect() async throws { let eventLoopGroup = MultiThreadedEventLoopGroup(numberOfThreads: 2) defer { XCTAssertNoThrow(try eventLoopGroup.syncShutdownGracefully()) } diff --git a/Tests/HummingbirdCoreTests/TLSTests.swift b/Tests/HummingbirdCoreTests/TLSTests.swift index 5ebc1b7b..c4b8885c 100644 --- a/Tests/HummingbirdCoreTests/TLSTests.swift +++ b/Tests/HummingbirdCoreTests/TLSTests.swift @@ -23,7 +23,7 @@ import NIOSSL import NIOTransportServices import XCTest -class HummingBirdTLSTests: XCTestCase { +final class HummingBirdTLSTests: XCTestCase { func testConnect() async throws { let eventLoopGroup = MultiThreadedEventLoopGroup(numberOfThreads: 2) defer { XCTAssertNoThrow(try eventLoopGroup.syncShutdownGracefully()) } diff --git a/Tests/HummingbirdCoreTests/TSTests.swift b/Tests/HummingbirdCoreTests/TSTests.swift index 25bc04ec..c6a0c3ae 100644 --- a/Tests/HummingbirdCoreTests/TSTests.swift +++ b/Tests/HummingbirdCoreTests/TSTests.swift @@ -23,7 +23,7 @@ import NIOSSL import NIOTransportServices import XCTest -class TransportServicesTests: XCTestCase { +final class TransportServicesTests: XCTestCase { func randomBuffer(size: Int) -> ByteBuffer { var data = [UInt8](repeating: 0, count: size) data = data.map { _ in UInt8.random(in: 0...255) } diff --git a/Tests/HummingbirdTests/CookiesTests.swift b/Tests/HummingbirdTests/CookiesTests.swift index c3b53136..b78e5938 100644 --- a/Tests/HummingbirdTests/CookiesTests.swift +++ b/Tests/HummingbirdTests/CookiesTests.swift @@ -16,7 +16,7 @@ import HummingbirdTesting import XCTest -class CookieTests: XCTestCase { +final class CookieTests: XCTestCase { func testNameValue() { let cookie = Cookie(from: "name=value") XCTAssertEqual(cookie?.name, "name") diff --git a/Tests/HummingbirdTests/DateCacheTests.swift b/Tests/HummingbirdTests/DateCacheTests.swift index 5c0a17d0..ddd425b5 100644 --- a/Tests/HummingbirdTests/DateCacheTests.swift +++ b/Tests/HummingbirdTests/DateCacheTests.swift @@ -17,7 +17,7 @@ import Foundation import HummingbirdTesting import XCTest -class HummingbirdDateTests: XCTestCase { +final class HummingbirdDateTests: XCTestCase { func testRFC1123Renderer() { let formatter = DateFormatter() formatter.locale = Locale(identifier: "en_US_POSIX") diff --git a/Tests/HummingbirdTests/FileIOTests.swift b/Tests/HummingbirdTests/FileIOTests.swift index c5b63a85..10dd2535 100644 --- a/Tests/HummingbirdTests/FileIOTests.swift +++ b/Tests/HummingbirdTests/FileIOTests.swift @@ -16,7 +16,7 @@ import Hummingbird import HummingbirdTesting import XCTest -class FileIOTests: XCTestCase { +final class FileIOTests: XCTestCase { static func randomBuffer(size: Int) -> ByteBuffer { var data = [UInt8](repeating: 0, count: size) data = data.map { _ in UInt8.random(in: 0...255) } diff --git a/Tests/HummingbirdTests/FileMiddlewareTests.swift b/Tests/HummingbirdTests/FileMiddlewareTests.swift index e6581066..e7edb39e 100644 --- a/Tests/HummingbirdTests/FileMiddlewareTests.swift +++ b/Tests/HummingbirdTests/FileMiddlewareTests.swift @@ -18,7 +18,7 @@ import Hummingbird import HummingbirdTesting import XCTest -class FileMiddlewareTests: XCTestCase { +final class FileMiddlewareTests: XCTestCase { static func randomBuffer(size: Int) -> ByteBuffer { var data = [UInt8](repeating: 0, count: size) data = data.map { _ in UInt8.random(in: 0...255) } diff --git a/Tests/HummingbirdTests/HTTPTests.swift b/Tests/HummingbirdTests/HTTPTests.swift index 0d1cf29c..7635a072 100644 --- a/Tests/HummingbirdTests/HTTPTests.swift +++ b/Tests/HummingbirdTests/HTTPTests.swift @@ -16,7 +16,7 @@ import Hummingbird import HummingbirdCore import XCTest -class HTTPTests: XCTestCase { +final class HTTPTests: XCTestCase { func testURI(_ uri: URI, _ component: KeyPath, _ value: T) { XCTAssertEqual(uri[keyPath: component], value) } diff --git a/Tests/HummingbirdTests/HummingBirdJSONTests.swift b/Tests/HummingbirdTests/HummingBirdJSONTests.swift index 93fc1528..1f3270bf 100644 --- a/Tests/HummingbirdTests/HummingBirdJSONTests.swift +++ b/Tests/HummingbirdTests/HummingBirdJSONTests.swift @@ -17,7 +17,7 @@ import HummingbirdTesting import Logging import XCTest -class HummingbirdJSONTests: XCTestCase { +final class HummingbirdJSONTests: XCTestCase { struct User: ResponseCodable { let name: String let email: String diff --git a/Tests/HummingbirdTests/TrieRouterTests.swift b/Tests/HummingbirdTests/TrieRouterTests.swift index 5cdc9e4e..329bdc21 100644 --- a/Tests/HummingbirdTests/TrieRouterTests.swift +++ b/Tests/HummingbirdTests/TrieRouterTests.swift @@ -15,7 +15,7 @@ @testable @_spi(Internal) import Hummingbird import XCTest -class TrieRouterTests: XCTestCase { +final class TrieRouterTests: XCTestCase { func testPathComponentsTrie() { let trieBuilder = RouterPathTrieBuilder() trieBuilder.addEntry("/usr/local/bin", value: "test1") diff --git a/Tests/HummingbirdTests/URLEncodedForm/Application+URLEncodedFormTests.swift b/Tests/HummingbirdTests/URLEncodedForm/Application+URLEncodedFormTests.swift index 4245ba3b..2cb589f1 100644 --- a/Tests/HummingbirdTests/URLEncodedForm/Application+URLEncodedFormTests.swift +++ b/Tests/HummingbirdTests/URLEncodedForm/Application+URLEncodedFormTests.swift @@ -18,7 +18,7 @@ import Logging import NIOCore import XCTest -class HummingBirdURLEncodedTests: XCTestCase { +final class HummingBirdURLEncodedTests: XCTestCase { struct User: ResponseCodable { let name: String let email: String diff --git a/Tests/HummingbirdTests/URLEncodedForm/URLDecoderTests.swift b/Tests/HummingbirdTests/URLEncodedForm/URLDecoderTests.swift index 3768aa1e..8da4f379 100644 --- a/Tests/HummingbirdTests/URLEncodedForm/URLDecoderTests.swift +++ b/Tests/HummingbirdTests/URLEncodedForm/URLDecoderTests.swift @@ -15,7 +15,7 @@ @testable import Hummingbird import XCTest -class URLDecodedFormDecoderTests: XCTestCase { +final class URLDecodedFormDecoderTests: XCTestCase { func testForm(_ value: Input, query: String, decoder: URLEncodedFormDecoder = .init()) { do { let value2 = try decoder.decode(Input.self, from: query) diff --git a/Tests/HummingbirdTests/URLEncodedForm/URLEncodedNodeTests.swift b/Tests/HummingbirdTests/URLEncodedForm/URLEncodedNodeTests.swift index 33df91e6..c9c51f92 100644 --- a/Tests/HummingbirdTests/URLEncodedForm/URLEncodedNodeTests.swift +++ b/Tests/HummingbirdTests/URLEncodedForm/URLEncodedNodeTests.swift @@ -15,7 +15,7 @@ @testable import Hummingbird import XCTest -class URLEncodedFormNodeTests: XCTestCase { +final class URLEncodedFormNodeTests: XCTestCase { static func XCTAssertEncodedEqual(_ lhs: String, _ rhs: String) { let lhs = lhs.split(separator: "&") .sorted { $0 < $1 } diff --git a/Tests/HummingbirdTests/URLEncodedForm/URLEncoderTests.swift b/Tests/HummingbirdTests/URLEncodedForm/URLEncoderTests.swift index 71bae7c5..4f638d2f 100644 --- a/Tests/HummingbirdTests/URLEncodedForm/URLEncoderTests.swift +++ b/Tests/HummingbirdTests/URLEncodedForm/URLEncoderTests.swift @@ -15,7 +15,7 @@ import Hummingbird import XCTest -class URLEncodedFormEncoderTests: XCTestCase { +final class URLEncodedFormEncoderTests: XCTestCase { static func XCTAssertEncodedEqual(_ lhs: String, _ rhs: String) { let lhs = lhs.split(separator: "&") .sorted { $0 < $1 } diff --git a/Tests/HummingbirdTests/UtilsTests.swift b/Tests/HummingbirdTests/UtilsTests.swift index f1e94992..a4aea091 100644 --- a/Tests/HummingbirdTests/UtilsTests.swift +++ b/Tests/HummingbirdTests/UtilsTests.swift @@ -15,7 +15,7 @@ import HummingbirdCore import XCTest -class FlatDictionaryTests: XCTestCase { +final class FlatDictionaryTests: XCTestCase { func testLiteralInit() { let a: FlatDictionary = ["test": "value", "key2": "value2"] XCTAssertEqual(a["test"], "value")