mirror of
https://github.com/yonaskolb/XcodeGen.git
synced 2026-03-18 20:02:25 +00:00
Add support for conditionally linking dependencies based on platform (#1087)
* Add initial support for conditional platform dependencies * Add tests for conditional platforms * Update docs and changelog * Respond to PR feedback * Change name of field from 'conditionalPlatforms' to 'platforms' Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>
This commit is contained in:
co-authored by
Yonas Kolb
parent
4455919be3
commit
81bd52be4b
@@ -354,9 +354,9 @@ class PBXProjGeneratorTests: XCTestCase {
|
||||
let target1 = Target(name: "TestAll", type: .application, platform: .iOS, sources: ["Sources"])
|
||||
let target2 = Target(name: "TestiOS", type: .application, platform: .iOS, sources: ["Sources"])
|
||||
let target3 = Target(name: "TestmacOS", type: .application, platform: .iOS, sources: ["Sources"])
|
||||
let dependency1 = Dependency(type: .target, reference: "TestAll", platform: .all)
|
||||
let dependency2 = Dependency(type: .target, reference: "TestiOS", platform: .iOS)
|
||||
let dependency3 = Dependency(type: .target, reference: "TestmacOS", platform: .macOS)
|
||||
let dependency1 = Dependency(type: .target, reference: "TestAll", platformFilter: .all)
|
||||
let dependency2 = Dependency(type: .target, reference: "TestiOS", platformFilter: .iOS)
|
||||
let dependency3 = Dependency(type: .target, reference: "TestmacOS", platformFilter: .macOS)
|
||||
let target = Target(name: "Test", type: .application, platform: .iOS, sources: ["Sources"], dependencies: [dependency1, dependency2, dependency3])
|
||||
let project = Project(basePath: directoryPath, name: "Test", targets: [target, target1, target2, target3])
|
||||
|
||||
|
||||
Reference in New Issue
Block a user