Repository navigation
test:helper: pass swift-testing's macro plugin path on Command Line Tools - #30
Merged
Merged
Conversation
On a clean macOS 27 machine with only the Command Line Tools (Swift 6.4, swiftbuild default), swift test fails with "plugin for module 'TestingMacros' not found": the plugin ships under usr/lib/swift/host/plugins/testing but the build does not pass it. Pass that directory when the developer dir is the Command Line Tools; Xcode is unchanged. Found by the clean-machine gate (#9).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Found by the clean-machine gate (#9) in a macOS 27.0 (26A428) VM with only the Command Line Tools 27 (Swift 6.4):
npm run build:helperbuilds, butnpm run test:helper'sswift testfails to compile every test withexternal macro implementation type 'TestingMacros.…' could not be found … plugin for module 'TestingMacros' not found. The plugin is present at/Library/Developer/CommandLineTools/usr/lib/swift/host/plugins/testing/libTestingMacros.dylib; the default (swiftbuild) build system does not hand that directory to the compiler.Change: when the developer directory (
DEVELOPER_DIRorxcode-select -p) is the Command Line Tools and that directory exists,swift testgets-Xswiftc -plugin-path -Xswiftc <dir>. Xcode toolchains get no extra arguments (unchanged path, verified on Xcode/Swift 6.3.3 machines before).Verified in the guest: unpatched, swift tests FAILED (node-driven 7/7 pass); patched,
test:helperswift 55 tests in 5 suites passed, node 7/7.accept-nativeitems 1 and 10 runtest:helper, so the gate's acceptance run needs this on the checked-out HEAD.