@@ -615,7 +615,7 @@ final class BuildPlanTests: XCTestCase {
615
615
path: " /Bar " ,
616
616
url: " /Bar " ,
617
617
products: [
618
- ProductDescription ( name: " Bar " , type: . library( . dynamic) , targets: [ " Bar " ] ) ,
618
+ ProductDescription ( name: " Bar-Baz " , type: . library( . dynamic) , targets: [ " Bar " ] ) ,
619
619
] ,
620
620
targets: [
621
621
TargetDescription ( name: " Bar " , dependencies: [ ] ) ,
@@ -628,7 +628,7 @@ final class BuildPlanTests: XCTestCase {
628
628
PackageDependencyDescription ( url: " /Bar " , requirement: . upToNextMajor( from: " 1.0.0 " ) ) ,
629
629
] ,
630
630
targets: [
631
- TargetDescription ( name: " Foo " , dependencies: [ " Bar " ] ) ,
631
+ TargetDescription ( name: " Foo " , dependencies: [ " Bar-Baz " ] ) ,
632
632
] ) ,
633
633
]
634
634
)
@@ -639,35 +639,35 @@ final class BuildPlanTests: XCTestCase {
639
639
result. checkTargetsCount ( 2 )
640
640
641
641
let fooLinkArgs = try result. buildProduct ( for: " Foo " ) . linkArguments ( )
642
- let barLinkArgs = try result. buildProduct ( for: " Bar " ) . linkArguments ( )
642
+ let barLinkArgs = try result. buildProduct ( for: " Bar-Baz " ) . linkArguments ( )
643
643
644
644
#if os(macOS)
645
645
XCTAssertEqual ( fooLinkArgs, [
646
646
" /fake/path/to/swiftc " , " -g " , " -L " , " /path/to/build/debug " ,
647
- " -o " , " /path/to/build/debug/Foo " , " -module-name " , " Foo " , " -lBar " , " -emit-executable " ,
647
+ " -o " , " /path/to/build/debug/Foo " , " -module-name " , " Foo " , " -lBar-Baz " , " -emit-executable " ,
648
648
" @/path/to/build/debug/Foo.product/Objects.LinkFileList " ,
649
649
] )
650
650
651
651
XCTAssertEqual ( barLinkArgs, [
652
652
" /fake/path/to/swiftc " , " -g " , " -L " , " /path/to/build/debug " , " -o " ,
653
- " /path/to/build/debug/libBar.dylib " ,
654
- " -module-name " , " Bar " , " -emit-library " ,
655
- " @/path/to/build/debug/Bar.product/Objects.LinkFileList " ,
653
+ " /path/to/build/debug/libBar-Baz .dylib " ,
654
+ " -module-name " , " Bar_Baz " , " -emit-library " ,
655
+ " @/path/to/build/debug/Bar-Baz .product/Objects.LinkFileList " ,
656
656
] )
657
657
#else
658
658
XCTAssertEqual ( fooLinkArgs, [
659
659
" /fake/path/to/swiftc " , " -g " , " -L " , " /path/to/build/debug " ,
660
- " -o " , " /path/to/build/debug/Foo " , " -module-name " , " Foo " , " -lBar " , " -emit-executable " ,
660
+ " -o " , " /path/to/build/debug/Foo " , " -module-name " , " Foo " , " -lBar-Baz " , " -emit-executable " ,
661
661
" -Xlinker " , " -rpath=$ORIGIN " ,
662
662
" @/path/to/build/debug/Foo.product/Objects.LinkFileList " ,
663
663
] )
664
664
665
665
XCTAssertEqual ( barLinkArgs, [
666
666
" /fake/path/to/swiftc " , " -g " , " -L " , " /path/to/build/debug " , " -o " ,
667
- " /path/to/build/debug/libBar.so " ,
668
- " -module-name " , " Bar " , " -emit-library " ,
667
+ " /path/to/build/debug/libBar-Baz .so " ,
668
+ " -module-name " , " Bar_Baz " , " -emit-library " ,
669
669
" -Xlinker " , " -rpath=$ORIGIN " ,
670
- " @/path/to/build/debug/Bar.product/Objects.LinkFileList " ,
670
+ " @/path/to/build/debug/Bar-Baz .product/Objects.LinkFileList " ,
671
671
] )
672
672
#endif
673
673
0 commit comments