From 79e5fb4fe4d1d47f741f68b5f984d9340b92b806 Mon Sep 17 00:00:00 2001 From: Peter Adams <63288215+PeterAdams-A@users.noreply.github.com> Date: Wed, 12 Jun 2024 10:53:26 +0100 Subject: [PATCH] Raise minimum swift version to 5.8 (#147) Motivation: It's consistant with support policy (see https://github.com/apple/swift-metrics/pull/141). It matches what's being tested. It will make future changes adopting new features easier. Modifications: Bump swift tools version to 5.8 Remove linux tests and test discovery flag which are not required. Result: Will not longer build using swift before 5.8 - older compilers will find older versions of this library when resolving versions. --- Package.swift | 2 +- Tests/LinuxMain.swift | 32 -------------------------------- docker/docker-compose.yaml | 2 +- 3 files changed, 2 insertions(+), 34 deletions(-) delete mode 100644 Tests/LinuxMain.swift diff --git a/Package.swift b/Package.swift index a0e7e5b..d9f7f74 100644 --- a/Package.swift +++ b/Package.swift @@ -1,4 +1,4 @@ -// swift-tools-version:5.6 +// swift-tools-version:5.8 //===----------------------------------------------------------------------===// // // This source file is part of the Swift Metrics API open source project diff --git a/Tests/LinuxMain.swift b/Tests/LinuxMain.swift deleted file mode 100644 index 50ad1ac..0000000 --- a/Tests/LinuxMain.swift +++ /dev/null @@ -1,32 +0,0 @@ -//===----------------------------------------------------------------------===// -// -// This source file is part of the Swift Metrics API open source project -// -// Copyright (c) 2018-2019 Apple Inc. and the Swift Metrics API project authors -// Licensed under Apache License v2.0 -// -// See LICENSE.txt for license information -// See CONTRIBUTORS.txt for the list of Swift Metrics API project authors -// -// SPDX-License-Identifier: Apache-2.0 -// -//===----------------------------------------------------------------------===// -// -// LinuxMain.swift -// -import XCTest - -/// -/// NOTE: This file was generated by generate_linux_tests.rb -/// -/// Do NOT edit this file directly as it will be regenerated automatically when needed. -/// - -#if os(Linux) || os(FreeBSD) -@testable import MetricsTests - -XCTMain([ - testCase(MetricsExtensionsTests.allTests), - testCase(MetricsTests.allTests), -]) -#endif diff --git a/docker/docker-compose.yaml b/docker/docker-compose.yaml index b752fd6..8d26d65 100644 --- a/docker/docker-compose.yaml +++ b/docker/docker-compose.yaml @@ -28,7 +28,7 @@ services: test: <<: *common - command: /bin/bash -xcl "swift test -Xswiftc -warnings-as-errors --enable-test-discovery $${SANITIZER_ARG-}" + command: /bin/bash -xcl "swift test -Xswiftc -warnings-as-errors $${SANITIZER_ARG-}" # util