11// RUN: %empty-directory(%t)
22// REQUIRES: VENDOR=apple
33
4+ /// Prepare the SDK.
5+ // RUN: cp -r %S/Inputs/public-private-sdk %t/sdk
6+ // RUN: %target-swift-frontend -emit-module -module-name PublicSwift \
7+ // RUN: %t/sdk/System/Library/Frameworks/PublicSwift.framework/Modules/PublicSwift.swiftmodule/source.swift \
8+ // RUN: -o %t/sdk/System/Library/Frameworks/PublicSwift.framework/Modules/PublicSwift.swiftmodule/%target-swiftmodule-name
9+ // RUN: %target-swift-frontend -emit-module -module-name PrivateSwift \
10+ // RUN: %t/sdk/System/Library/PrivateFrameworks/PrivateSwift.framework/Modules/PrivateSwift.swiftmodule/source.swift \
11+ // RUN: -o %t/sdk/System/Library/PrivateFrameworks/PrivateSwift.framework/Modules/PrivateSwift.swiftmodule/%target-swiftmodule-name
12+
413/// Expect warnings when building a public client.
5- // RUN: %target-swift-frontend -sdk %S/Inputs/public-private- sdk -typecheck -module-cache-path %t %s \
6- // RUN: -F %S/Inputs/public-private- sdk/System/Library/PrivateFrameworks/ \
14+ // RUN: %target-swift-frontend -typecheck - sdk %t/ sdk -module-cache-path %t %s \
15+ // RUN: -F %t/ sdk/System/Library/PrivateFrameworks/ \
716// RUN: -library-level api -verify -D PUBLIC_IMPORTS
817
918/// Expect no warnings when building an SPI client.
10- // RUN: %target-swift-frontend -sdk %S/Inputs/public-private- sdk -typecheck -module-cache-path %t %s \
11- // RUN: -F %S/Inputs/public-private- sdk/System/Library/PrivateFrameworks/ \
19+ // RUN: %target-swift-frontend -typecheck - sdk %t/ sdk -module-cache-path %t %s \
20+ // RUN: -F %t/ sdk/System/Library/PrivateFrameworks/ \
1221// RUN: -library-level spi -D PUBLIC_IMPORTS
1322
1423/// Expect no warnings when building a client with some other library level.
15- // RUN: %target-swift-frontend -sdk %S/Inputs/public-private- sdk -typecheck -module-cache-path %t %s \
16- // RUN: -F %S/Inputs/public-private- sdk/System/Library/PrivateFrameworks/ \
24+ // RUN: %target-swift-frontend -typecheck - sdk %t/ sdk -module-cache-path %t %s \
25+ // RUN: -F %t/ sdk/System/Library/PrivateFrameworks/ \
1726// RUN: -D PUBLIC_IMPORTS
18- // RUN: %target-swift-frontend -sdk %S/Inputs/public-private- sdk -typecheck -module-cache-path %t %s \
19- // RUN: -F %S/Inputs/public-private- sdk/System/Library/PrivateFrameworks/ \
27+ // RUN: %target-swift-frontend -typecheck - sdk %t/ sdk -module-cache-path %t %s \
28+ // RUN: -F %t/ sdk/System/Library/PrivateFrameworks/ \
2029// RUN: -library-level other -D PUBLIC_IMPORTS
2130#if PUBLIC_IMPORTS
2231import PublicSwift
@@ -28,8 +37,8 @@ import FullyPrivateClang // expected-warning{{private module 'FullyPrivateClang'
2837import main // expected-warning{{'implementation-only-import-suggestion.swift' is part of module 'main'; ignoring import}}
2938
3039/// Expect no warnings with implementation-only imports.
31- // RUN: %target-swift-frontend -sdk %S/Inputs/public-private- sdk -typecheck -module-cache-path %t %s \
32- // RUN: -F %S/Inputs/public-private- sdk/System/Library/PrivateFrameworks/ \
40+ // RUN: %target-swift-frontend -typecheck - sdk %t/ sdk -module-cache-path %t %s \
41+ // RUN: -F %t/ sdk/System/Library/PrivateFrameworks/ \
3342// RUN: -library-level api -D IMPL_ONLY_IMPORTS
3443#elseif IMPL_ONLY_IMPORTS
3544
0 commit comments