-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Open
Labels
Description
Is it reproducible with SwiftPM command-line tools: swift build
, swift test
, swift package
etc?
- Confirmed reproduction steps with SwiftPM CLI. The description text must include reproduction steps with either of command-line SwiftPM commands,
swift build
,swift test
,swift package
etc.
Description
The PackageCommandSwiftBuildTest.testCommandPluginCompilationError
does as swift build --build-system swiftbuild
against a package that has a Command Plugin, which has a compilation error.
However, the test does not throw an error when using the SwiftBuild backend, but it does when using the native build system.
Expected behavior
Building the sample project using the SwiftBuild build system either fails in a similar manner as the Native build system.
Actual behavior
No error is thrown.
Steps to reproduce
- Clone the repository
- Run the following and expect a non-zero return code
swift run swift-build --build-system swiftbuild --package-path Fixtures/Miscellaneous/Plugins/CommandPluginUnsuccessful
Swift Package Manager version/commit hash
5c57a39a3cecc865dfdecbbfae0f62cc13780e00
Swift & OS version (output of swift --version ; uname -a
)
Observed on MacOS and linux
❯ uname -a
Darwin BKs-Work-M1Pro-MacBook-Pro-3.local 25.0.0 Darwin Kernel Version 25.0.0: Sat Jul 12 00:30:16 PDT 2025; root:xnu_development-12377.0.154.0.2~25/DEVELOPMENT_ARM64_T6000 arm64
and
build-user@a73e2eb7c3de:/source$ uname -a
Linux a73e2eb7c3de 6.1.68 #1 SMP Fri Nov 22 18:05:17 UTC 2024 aarch64 aarch64 aarch64 GNU/Linux