Skip to content

Commit d2d0d1f

Browse files
committed
SwiftBuild: Enable traits support
When Creasting the SwiftBuildSystem Factory, the traits configuration was not passed when loading the package graph. Update the factory to pass the traits configuration during package resolution, and remove the `withKnownIssues` in TraitTests as it relates to SwiftBuild. Also augment te tests to run against all build configuration.
1 parent cdb5674 commit d2d0d1f

File tree

2 files changed

+203
-90
lines changed

2 files changed

+203
-90
lines changed

Sources/CoreCommands/BuildSystemSupport.swift

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,8 @@ private struct SwiftBuildSystemFactory: BuildSystemFactory {
120120
buildParameters: productsBuildParameters ?? self.swiftCommandState.productsBuildParameters,
121121
packageGraphLoader: packageGraphLoader ?? {
122122
try await self.swiftCommandState.loadPackageGraph(
123-
explicitProduct: explicitProduct
123+
explicitProduct: explicitProduct,
124+
traitConfiguration: traitConfiguration,
124125
)
125126
},
126127
packageManagerResourcesDirectory: swiftCommandState.packageManagerResourcesDirectory,

0 commit comments

Comments
 (0)