diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 0e5a0c30..229fc870 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -13,6 +13,22 @@ jobs: unit-tests: uses: vapor/ci/.github/workflows/run-unit-tests.yml@main + pure-fluent-integration-test: + if: ${{ !(github.event.pull_request.draft || false) }} + runs-on: ubuntu-latest + container: swift:5.10-jammy + steps: + - name: Check out sql-kit + uses: actions/checkout@v4 + with: { path: sql-kit, repository: vapor/sql-kit } + - name: Check out fluent-kit + uses: actions/checkout@v4 + with: { path: fluent-kit, repository: vapor/fluent-kit } + - name: Set up and run FluentKit tests + run: | + swift package --package-path fluent-kit edit --path sql-kit sql-kit + swift test --package-path fluent-kit --sanitize=thread + integration-tests: if: ${{ !(github.event.pull_request.draft || false) }} services: diff --git a/Package.swift b/Package.swift index 89961756..f707b210 100644 --- a/Package.swift +++ b/Package.swift @@ -24,6 +24,7 @@ let package = Package( name: "SQLKit", dependencies: [ .product(name: "Logging", package: "swift-log"), + .product(name: "NIO", package: "swift-nio"), .product(name: "NIOCore", package: "swift-nio"), .product(name: "Collections", package: "swift-collections"), ], @@ -48,7 +49,6 @@ let package = Package( ) var swiftSettings: [SwiftSetting] { [ - .enableUpcomingFeature("ExistentialAny"), .enableUpcomingFeature("ConciseMagicFile"), .enableUpcomingFeature("ForwardTrailingClosures"), .enableUpcomingFeature("ImportObjcForwardDeclarations"), diff --git a/Package@swift-5.9.swift b/Package@swift-5.9.swift new file mode 100644 index 00000000..185aea77 --- /dev/null +++ b/Package@swift-5.9.swift @@ -0,0 +1,61 @@ +// swift-tools-version:5.9 +import PackageDescription + +let package = Package( + name: "sql-kit", + platforms: [ + .macOS(.v10_15), + .iOS(.v13), + .watchOS(.v6), + .tvOS(.v13), + ], + products: [ + .library(name: "SQLKit", targets: ["SQLKit"]), + .library(name: "SQLKitBenchmark", targets: ["SQLKitBenchmark"]), + ], + dependencies: [ + .package(url: "https://github.com/apple/swift-nio.git", from: "2.64.0"), + .package(url: "https://github.com/apple/swift-log.git", from: "1.5.4"), + .package(url: "https://github.com/apple/swift-collections.git", from: "1.1.0"), + .package(url: "https://github.com/apple/swift-docc-plugin.git", from: "1.3.0"), + ], + targets: [ + .target( + name: "SQLKit", + dependencies: [ + .product(name: "Logging", package: "swift-log"), + .product(name: "NIO", package: "swift-nio"), + .product(name: "NIOCore", package: "swift-nio"), + .product(name: "Collections", package: "swift-collections"), + ], + swiftSettings: swiftSettings + ), + .target( + name: "SQLKitBenchmark", + dependencies: [ + .target(name: "SQLKit"), + ], + swiftSettings: swiftSettings + ), + .testTarget( + name: "SQLKitTests", + dependencies: [ + .target(name: "SQLKit"), + .target(name: "SQLKitBenchmark"), + ], + swiftSettings: swiftSettings + ), + ] +) + +var swiftSettings: [SwiftSetting] { [ + .enableUpcomingFeature("ExistentialAny"), + .enableUpcomingFeature("ConciseMagicFile"), + .enableUpcomingFeature("ForwardTrailingClosures"), + .enableUpcomingFeature("ImportObjcForwardDeclarations"), + .enableUpcomingFeature("DisableOutwardActorInference"), + .enableUpcomingFeature("IsolatedDefaultValues"), + .enableUpcomingFeature("GlobalConcurrency"), + .enableUpcomingFeature("StrictConcurrency"), + .enableExperimentalFeature("StrictConcurrency=complete"), +] } diff --git a/Sources/SQLKit/Exports.swift b/Sources/SQLKit/Exports.swift index 370dd880..3fbde01f 100644 --- a/Sources/SQLKit/Exports.swift +++ b/Sources/SQLKit/Exports.swift @@ -1,3 +1,3 @@ -@_documentation(visibility: internal) @_exported import protocol NIOCore.EventLoop -@_documentation(visibility: internal) @_exported import class NIOCore.EventLoopFuture +@_documentation(visibility: internal) @_exported import protocol NIO.EventLoop +@_documentation(visibility: internal) @_exported import class NIO.EventLoopFuture @_documentation(visibility: internal) @_exported import struct Logging.Logger