Skip to content

Commit c285c5e

Browse files
committed
[ModuleInterface] Improve swift-export-as test to use the swiftinterfaces
1 parent 39fb1c5 commit c285c5e

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

test/ModuleInterface/swift-export-as.swift

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,19 @@
4848
// RUN: cat %t/ClientLib.swiftinterface | %FileCheck --check-prefixes=CLIENT-PUBLIC %s
4949
// RUN: cat %t/ClientLib.private.swiftinterface | %FileCheck --check-prefixes=CLIENT-PRIVATE %s
5050

51+
/// Check that we get the same behavior using swiftinterfaces only.
52+
// RUN: rm -f %t/PrivateLib.swiftmodule %t/PublicLib.swiftmodule
53+
// RUN: %target-swift-frontend -emit-module %t/ClientLib.swift -I %t \
54+
// RUN: -swift-version 5 -enable-library-evolution \
55+
// RUN: -o %t/ClientLib.swiftmodule \
56+
// RUN: -emit-module-interface-path %t/ClientLib.swiftinterface \
57+
// RUN: -emit-private-module-interface-path %t/ClientLib.private.swiftinterface \
58+
// RUN: -enable-experimental-feature ModuleInterfaceExportAs
59+
// RUN: %target-swift-typecheck-module-from-interface(%t/ClientLib.swiftinterface) -I %t
60+
// RUN: %target-swift-typecheck-module-from-interface(%t/ClientLib.private.swiftinterface) -I %t
61+
// RUN: cat %t/ClientLib.swiftinterface | %FileCheck --check-prefixes=CLIENT-PUBLIC %s
62+
// RUN: cat %t/ClientLib.private.swiftinterface | %FileCheck --check-prefixes=CLIENT-PRIVATE %s
63+
5164
//--- PrivateLib.swift
5265

5366
public struct PrivateNameStruct {}

0 commit comments

Comments
 (0)