-
Notifications
You must be signed in to change notification settings - Fork 80
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add integration tests for static-linking of Foundation (#87)
Implementation: apple/swift-corelibs-foundation#2996 and apple/swift#35936
- Loading branch information
1 parent
7d6bf13
commit bc6ce67
Showing
4 changed files
with
38 additions
and
0 deletions.
There are no files selected for viewing
11 changes: 11 additions & 0 deletions
11
test-foundation-package/test-foundation-networking-static-stdlib.test
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
REQUIRES: platform=Linux | ||
RUN: rm -rf %t | ||
RUN: mkdir -p %t | ||
RUN: %{swiftc} -static-stdlib %S/test-foundation-networking.swift -o %t/test-foundation-networking | ||
RUN: %t/test-foundation-networking | %{FileCheck} %s | ||
RUN: ldd %t/test-foundation-networking | %{FileCheck} --check-prefix LDD %s | ||
|
||
CHECK: http://example.com | ||
LDD-NOT: libFoundation.so | ||
LDD-NOT: libFoundationNetworking.so | ||
LDD-NOT: libCoreFoundation.so |
This file contains 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
12 changes: 12 additions & 0 deletions
12
test-foundation-package/test-foundation-static-stdlib.test
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
REQUIRES: platform=Linux | ||
RUN: rm -rf %t | ||
RUN: mkdir -p %t | ||
RUN: %{swiftc} -static-stdlib %S/main.swift -o %t/main | ||
RUN: %t/main | %{FileCheck} %s | ||
RUN: ldd %t/main | %{FileCheck} --check-prefix LDD %s | ||
|
||
CHECK: Printing URL | ||
CHECK-NEXT: /tmp | ||
CHECK-NEXT: Done printing URL | ||
LDD-NOT: libFoundation.so | ||
LDD-NOT: libCoreFoundation.so |
10 changes: 10 additions & 0 deletions
10
test-foundation-package/test-foundation-xml-static-stdlib.test
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
REQUIRES: platform=Linux | ||
RUN: rm -rf %t | ||
RUN: mkdir -p %t | ||
RUN: %{swiftc} -static-stdlib %S/test-foundation-xml.swift -o %t/test-foundation-xml | ||
RUN: %t/test-foundation-xml | %{FileCheck} %s | ||
RUN: ldd %t/test-foundation-xml | %{FileCheck} --check-prefix LDD %s | ||
CHECK: NSXMLDocument | ||
LDD-NOT: libFoundation.so | ||
LDD-NOT: libFoundationXML.so | ||
LDD-NOT: libCoreFoundation.so |