Skip to content

Commit ed877ff

Browse files
committed
[Test] Make more permissive checks against the format of -Rmodule-loading
1 parent f184504 commit ed877ff

7 files changed

+23
-23
lines changed

test/Frontend/module-alias-diags.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
// RUN: %target-swift-frontend -module-name LibA %t/FileLib.swift -module-alias XLogging=AppleLogging -I %t -emit-module -emit-module-path %t/LibA.swiftmodule -Rmodule-loading 2> %t/result-LibA.output
1515
// RUN: test -f %t/LibA.swiftmodule
1616
// RUN: %FileCheck %s -input-file %t/result-LibA.output -check-prefix CHECK-LOAD
17-
// CHECK-LOAD: remark: loaded module at {{.*}}AppleLogging.swiftmodule
17+
// CHECK-LOAD: remark: loaded module {{.*}}AppleLogging.swiftmodule
1818

1919
/// 2. Fail: trying to access a non-member of a module (with module aliasing) should fail with the module alias in the diags
2020
/// Try building module Lib that imports XLogging WITH -module-alias XLogging=AppleLogging

test/Frontend/module-alias-explicit-build.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,4 +48,4 @@
4848
// RUN: not test -f %t/inputs/Cat.swiftmodule
4949

5050
// RUN: %FileCheck %s -input-file %t/outputs/load-result.output -check-prefix CHECK
51-
// CHECK: remark: loaded module at {{.*}}Bar.swiftmodule
51+
// CHECK: remark: loaded module {{.*}}Bar.swiftmodule

test/Frontend/module-alias-for-client.swift

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
/// Check Lib.swiftmodule is created and AppleLogging.swiftmodule is loaded
2323
// RUN: test -f %t/Lib.swiftmodule
2424
// RUN: %FileCheck %s -input-file %t/result-Lib.output -check-prefix CHECK-Lib
25-
// CHECK-Lib: remark: loaded module at {{.*}}AppleLogging.swiftmodule
25+
// CHECK-Lib: remark: loaded module {{.*}}AppleLogging.swiftmodule
2626

2727
/// 3a. Client1
2828
/// Create module Client1 that imports Lib and XLogging, WITHOUT module aliasing for XLogging
@@ -31,8 +31,8 @@
3131
/// Check Client1.swiftmodule is created and Lib.swiftmodule and XLogging.swiftmodule are loaded
3232
// RUN: test -f %t/Client1.swiftmodule
3333
// RUN: %FileCheck %s -input-file %t/result-Client1.output -check-prefix CHECK-1
34-
// CHECK-1: remark: loaded module at {{.*}}XLogging.swiftmodule
35-
// CHECK-1: remark: loaded module at {{.*}}Lib.swiftmodule
34+
// CHECK-1: remark: loaded module {{.*}}XLogging.swiftmodule
35+
// CHECK-1: remark: loaded module {{.*}}Lib.swiftmodule
3636

3737
/// 3b. Client2
3838
/// Create a module Client2 that imports Lib and XLogging, WITH module aliasing for XLogging
@@ -42,10 +42,10 @@
4242
/// loaded but XLogging.swiftmodule is not loaded.
4343
// RUN: test -f %t/Client2.swiftmodule
4444
// RUN: %FileCheck %s -input-file %t/result-Client2.output -check-prefix CHECK-2A
45-
// CHECK-2A: remark: loaded module at {{.*}}AppleLogging.swiftmodule
46-
// CHECK-2A: remark: loaded module at {{.*}}Lib.swiftmodule
45+
// CHECK-2A: remark: loaded module {{.*}}AppleLogging.swiftmodule
46+
// CHECK-2A: remark: loaded module {{.*}}Lib.swiftmodule
4747
// RUN: not %FileCheck %s -input-file %t/result-Client2.output -check-prefix CHECK-2B
48-
// CHECK-2B: remark: loaded module at {{.*}}XLogging.swiftmodule
48+
// CHECK-2B: remark: loaded module {{.*}}XLogging.swiftmodule
4949

5050

5151
// BEGIN FileLogging.swift

test/Frontend/module-alias-for-lib-and-client.swift

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@
2323
// RUN: not test -f %t/XLogging.swiftmodule
2424

2525
// RUN: %FileCheck %s -input-file %t/result-Lib.output -check-prefix CHECK-Lib
26-
// CHECK-Lib: remark: loaded module at {{.*}}AppleLogging.swiftmodule
26+
// CHECK-Lib: remark: loaded module {{.*}}AppleLogging.swiftmodule
2727
// RUN: not %FileCheck %s -input-file %t/result-Lib.output -check-prefix CHECK-NOT-Lib
28-
// CHECK-NOT-Lib: remark: loaded module at {{.*}}XLogging.swiftmodule
28+
// CHECK-NOT-Lib: remark: loaded module {{.*}}XLogging.swiftmodule
2929

3030
/// 3a. Client1
3131
/// Create module Client1 that imports Lib and XLogging, WITH module aliasing for XLogging
@@ -37,10 +37,10 @@
3737
// RUN: test -f %t/AppleLogging.swiftmodule
3838
// RUN: not test -f %t/XLogging.swiftmodule
3939
// RUN: %FileCheck %s -input-file %t/result-Client1.output -check-prefix CHECK-CLIENT1
40-
// CHECK-CLIENT1: remark: loaded module at {{.*}}AppleLogging.swiftmodule
41-
// CHECK-CLIENT1: remark: loaded module at {{.*}}Lib.swiftmodule
40+
// CHECK-CLIENT1: remark: loaded module {{.*}}AppleLogging.swiftmodule
41+
// CHECK-CLIENT1: remark: loaded module {{.*}}Lib.swiftmodule
4242
// RUN: not %FileCheck %s -input-file %t/result-Client1.output -check-prefix CHECK-NOT-CLIENT1
43-
// CHECK-NOT-CLIENT1: remark: loaded module at {{.*}}XLogging.swiftmodule
43+
// CHECK-NOT-CLIENT1: remark: loaded module {{.*}}XLogging.swiftmodule
4444

4545
/// 3b. Client2
4646
/// Try creating module Client2 that imports Lib and XLogging, WITHOUT module aliasing
@@ -61,10 +61,10 @@
6161
// RUN: not test -f %t/XLogging.swiftmodule
6262

6363
// RUN: %FileCheck %s -input-file %t/result-Client3.output -check-prefix CHECK-CLIENT3
64-
// CHECK-CLIENT3: remark: loaded module at {{.*}}AppleLogging.swiftmodule
65-
// CHECK-CLIENT3: remark: loaded module at {{.*}}Lib.swiftmodule
64+
// CHECK-CLIENT3: remark: loaded module {{.*}}AppleLogging.swiftmodule
65+
// CHECK-CLIENT3: remark: loaded module {{.*}}Lib.swiftmodule
6666
// RUN: not %FileCheck %s -input-file %t/result-Client3.output -check-prefix CHECK-NOT-CLIENT3
67-
// CHECK-NOT-CLIENT3: remark: loaded module at {{.*}}XLogging.swiftmodule
67+
// CHECK-NOT-CLIENT3: remark: loaded module {{.*}}XLogging.swiftmodule
6868

6969
// BEGIN FileLogging.swift
7070
public struct Logger {

test/Frontend/module-alias-load.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
// RUN: not test -f %t/Cat.swiftmodule
1919

2020
// RUN: %FileCheck %s -input-file %t/load-result-foo.output -check-prefix CHECK-FOO
21-
// CHECK-FOO: remark: loaded module at {{.*}}Bar.swiftmodule
21+
// CHECK-FOO: remark: loaded module {{.*}}Bar.swiftmodule
2222

2323
/// Create a module Zoo that imports Cat with -module-alias Cat=Bar with a source loader
2424
// RUN: %target-swift-frontend -module-name Zoo %t/FileFoo.swift -module-alias Cat=Bar -I %t -emit-module -emit-module-path %t/Zoo.swiftmodule -enable-source-import -Rmodule-loading 2> %t/load-result-zoo.output
@@ -28,7 +28,7 @@
2828
// RUN: not test -f %t/Cat.swiftmodule
2929

3030
// RUN: %FileCheck %s -input-file %t/load-result-zoo.output -check-prefix CHECK-ZOO
31-
// CHECK-ZOO: remark: loaded module at {{.*}}Bar.swiftmodule
31+
// CHECK-ZOO: remark: loaded module {{.*}}Bar.swiftmodule
3232

3333

3434
// BEGIN FileBar.swift

test/Frontend/module-alias-serialize-swiftinterface.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,9 @@
3030

3131
/// Check AppleLogging.swiftmodule is loaded
3232
// RUN: %FileCheck %s -input-file %t/result-Lib.output -check-prefix CHECK-LOAD
33-
// CHECK-LOAD: remark: loaded module at {{.*}}AppleLogging.swiftmodule
33+
// CHECK-LOAD: remark: loaded module {{.*}}AppleLogging.swiftmodule
3434
// RUN: not %FileCheck %s -input-file %t/result-Lib.output -check-prefix CHECK-NOT-LOAD1
35-
// CHECK-NOT-LOAD1: remark: loaded module at {{.*}}XLogging.swiftmodule
35+
// CHECK-NOT-LOAD1: remark: loaded module {{.*}}XLogging.swiftmodule
3636

3737
/// Check imported modules contain AppleLogging, not XLogging
3838
// RUN: %FileCheck %s -input-file %t/Lib.swiftinterface -check-prefix CHECK-IMPORT

test/Frontend/module-alias-serialize-swiftmodule.swift

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,9 @@
3131

3232
/// Check AppleLogging.swiftmodule is loaded, and XLogging.swiftmodule is not loaded
3333
// RUN: %FileCheck %s -input-file %t/result-Lib.output -check-prefix CHECK-LOAD1
34-
// CHECK-LOAD1: remark: loaded module at {{.*}}AppleLogging.swiftmodule
34+
// CHECK-LOAD1: remark: loaded module {{.*}}AppleLogging.swiftmodule
3535
// RUN: not %FileCheck %s -input-file %t/result-Lib.output -check-prefix CHECK-NOT-LOAD1
36-
// CHECK-NOT-LOAD1: remark: loaded module at {{.*}}XLogging.swiftmodule
36+
// CHECK-NOT-LOAD1: remark: loaded module {{.*}}XLogging.swiftmodule
3737

3838
/// Check Lib.swiftmodule contains AppleLogging and NOT XLogging as an imported module
3939
/// in the binary
@@ -52,7 +52,7 @@
5252
// RUN: not test -f %t/XLogging.swiftmodule
5353

5454
// RUN: %FileCheck %s -input-file %t/result-Client.output -check-prefix CHECK-LOAD2
55-
// CHECK-LOAD2: remark: loaded module at {{.*}}Lib.swiftmodule
55+
// CHECK-LOAD2: remark: loaded module {{.*}}Lib.swiftmodule
5656

5757
/// Check Client.swiftmodule contains Lib as an imported module in the binary
5858
// RUN: llvm-bcanalyzer --dump %t/Client.swiftmodule | %FileCheck %s -check-prefix=BCANALYZER-IMPORT2

0 commit comments

Comments
 (0)