Automattic / Automattic-Tracks-iOS

Client library for tracking user events for later analysis
GNU General Public License v2.0
41 stars 12 forks source link

Update Swift tools version from 5.3 to 5.5 #206

Closed mokagio closed 2 years ago

mokagio commented 2 years ago

Notice that this introduces an error when running swift test:

$ swift test

Building for debugging...
/Users/gio/Developer/a8c/tracks-apple-pod/Sources/Model/ObjC/Common/Core Data/TracksContextManager.m:24:24: error: use of undeclared identifier 'SWIFTPM_MODULE_BUNDLE'
    NSBundle *bundle = SWIFTPM_MODULE_BUNDLE;
                       ^
1 error generated.
[0/6] Compiling TracksContextManager.m
error: fatalError

This is a known Swift Package Manager issue. See:

However, bundle exec fastlane test, which uses xcodebuild under the hood, works.

Given our workflow is based on Xcode locally and Fastlane in CI, the regression seems acceptable.

The reason I'm keen to upgrade to 5.5 is that it's the required tooling version to integrate Buildkite's Test Analytics. See https://github.com/buildkite/test-collector-swift/blob/v0.1.0/Package.swift#L1