// swift-tools-version: 6.0 // T-iOS-16 integration-CI package: Swift Testing suites against the REAL Node // server (self-bootstrapped by ServerHarness — spawns `tsx src/server.ts` on an // ephemeral loopback port; see ServerHarness.swift for the run modes). // Flat layout (plan §2): test sources live directly in ios/IntegrationTests/. // `scripts/` holds the per-package coverage gate used by .github/workflows/ios.yml. // // F3 · why this package depends on FOUR client packages while every other // package depends strictly downward: the access-token policy is duplicated in // three modules (SessionCore.AuthCookie, HostRegistry.AccessToken, // APIClient.AccessTokenRule) plus the server's own `WEBTERM_TOKEN_RE`, and the // orchestrator froze `WireProtocol` (a shared-secret helper does not belong in // the cross-language wire contract). No single package can therefore see all // three predicates at once — this test target is the ONLY place that can, so // the anti-drift guard lives here (TokenPolicyDriftTests). The same deps let // the token end-to-end leg drive the REAL client transport/HTTP layer against a // REAL token-gated server instead of fakes (AccessTokenGateTests). import PackageDescription let package = Package( name: "IntegrationTests", platforms: [.iOS(.v17), .macOS(.v14)], dependencies: [ .package(path: "../Packages/WireProtocol"), .package(path: "../Packages/SessionCore"), .package(path: "../Packages/HostRegistry"), .package(path: "../Packages/APIClient"), ], targets: [ .testTarget( name: "IntegrationTests", dependencies: [ .product(name: "WireProtocol", package: "WireProtocol"), .product(name: "SessionCore", package: "SessionCore"), .product(name: "HostRegistry", package: "HostRegistry"), .product(name: "APIClient", package: "APIClient"), ], path: ".", exclude: ["scripts"] ), ], swiftLanguageModes: [.v6] )