Files
swift-mirror/test/ModuleInterface/loading-remarks.swift
Alexis Laferrière fec0498c65 [Test] Use a clean module cache for more tests
Use a clean module cache in tests printing path to the
swiftmodule/swiftinterface used as it may change depending on previous
tests.
2022-10-31 10:58:56 -07:00

16 lines
724 B
Swift

/// Test the -Rmodule-loading flag.
// RUN: %empty-directory(%t)
// RUN: %empty-directory(%t/cache)
/// Create a simple module and interface.
// RUN: echo 'public func publicFunction() {}' > %t/TestModule.swift
// RUN: %target-swift-emit-module-interface(%t/TestModule.swiftinterface) %t/TestModule.swift
/// Use -Rmodule-loading in a client and look for the diagnostics output.
// RUN: %target-swift-frontend -typecheck %s -I %t -Rmodule-loading -module-cache-path %t/cache 2>&1 | %FileCheck %s
import TestModule
// CHECK: remark: loaded module at {{.*}}SwiftShims-{{.*}}.pcm
// CHECK: remark: loaded module at {{.*}}Swift.swiftmodule{{.*}}.swiftmodule
// CHECK: remark: loaded module at {{.*}}TestModule.swiftinterface