Skip to content

Commit 065420d

Browse files
committed
Fix old tests to use the new option
1 parent c5bbdbd commit 065420d

File tree

8 files changed

+22
-21
lines changed

8 files changed

+22
-21
lines changed

test/CAS/block-list.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
// RUN: %target-swift-frontend -scan-dependencies -module-name Test -O \
55
// RUN: -disable-implicit-string-processing-module-import -disable-implicit-concurrency-module-import \
66
// RUN: -blocklist-file %t/blocklist.yml -blocklist-file %t/empty.yml \
7-
// RUN: -scanner-prefix-map %t=/^tmp -I %t/include \
7+
// RUN: -scanner-prefix-map-paths %t /^tmp -I %t/include \
88
// RUN: %t/main.swift -o %t/deps.json -cache-compile-job -cas-path %t/cas
99

1010
// RUN: %{python} %S/Inputs/BuildCommandExtractor.py %t/deps.json clang:SwiftShims > %t/shim.cmd
@@ -38,7 +38,7 @@
3838
// RUN: -blocklist-file /^tmp/blocklist.yml -blocklist-file /^tmp/empty.yml \
3939
// RUN: -enable-layout-string-value-witnesses -enable-layout-string-value-witnesses-instantiation \
4040
// RUN: -enable-experimental-feature LayoutStringValueWitnesses -enable-experimental-feature LayoutStringValueWitnessesInstantiation \
41-
// RUN: -cache-replay-prefix-map /^tmp=%t \
41+
// RUN: -cache-replay-prefix-map /^tmp %t \
4242
// RUN: /^tmp/main.swift @%t/MyApp.cmd 2>&1 | %FileCheck %s --check-prefix CHECK-BLOCKED
4343

4444
// REQUIRES: swift_feature_LayoutStringValueWitnesses

test/CAS/cached_diagnostics_remap.swift

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,14 @@
44
/// Check path remapping.
55
// RUN: %target-swift-frontend -scan-dependencies -module-name Test -O -import-objc-header %t/objc.h -auto-bridging-header-chaining \
66
// RUN: -disable-implicit-string-processing-module-import -disable-implicit-concurrency-module-import -parse-stdlib \
7-
// RUN: %t/test.swift -o %t/deps.json -cache-compile-job -cas-path %t/cas -scanner-prefix-map %t=/^test -scanner-output-dir %t.noremap
7+
// RUN: %t/test.swift -o %t/deps.json -cache-compile-job -cas-path %t/cas -scanner-prefix-map-paths %t /^test -scanner-output-dir %t.noremap
88

99
// RUN: %{python} %S/Inputs/BuildCommandExtractor.py %t/deps.json bridgingHeader > %t/header.cmd
1010
// RUN: %target-swift-frontend @%t/header.cmd -disable-implicit-swift-modules -O -o %t/objc.pch 2>&1 | %FileCheck %s -check-prefix BRIDGE
1111
// RUN: %cache-tool -cas-path %t/cas -cache-tool-action print-output-keys -- \
1212
// RUN: %target-swift-frontend @%t/header.cmd -disable-implicit-swift-modules -O -o %t/objc.pch > %t/keys.json
1313
// RUN: %cache-tool -cas-path %t/cas -cache-tool-action render-diags %t/keys.json -- \
14-
// RUN: %target-swift-frontend @%t/header.cmd -disable-implicit-swift-modules -O -o %t/objc.pch -cache-replay-prefix-map /^test=%t 2>&1 \
14+
// RUN: %target-swift-frontend @%t/header.cmd -disable-implicit-swift-modules -O -o %t/objc.pch -cache-replay-prefix-map /^test %t 2>&1 \
1515
// RUN: | %FileCheck %s -check-prefix BRIDGE -check-prefix BRIDGE-REMAP
1616

1717
// RUN: %{python} %S/Inputs/ExtractOutputKey.py %t/keys.json > %t/key
@@ -33,7 +33,7 @@
3333
// RUN: -emit-module -o %t/test.swiftmodule /^test/test.swift > %t/cache_key.json
3434
// RUN: %cache-tool -cas-path %t/cas -cache-tool-action render-diags %t/cache_key.json -- %target-swift-frontend -cache-compile-job -module-name Test \
3535
// RUN: -O -cas-path %t/cas @%t/MyApp.cmd \
36-
// RUN: -emit-module -o %t/test.swiftmodule /^test/test.swift -cache-replay-prefix-map /^test=%t 2>&1 | %FileCheck %s --check-prefix REMAP
36+
// RUN: -emit-module -o %t/test.swiftmodule /^test/test.swift -cache-replay-prefix-map /^test %t 2>&1 | %FileCheck %s --check-prefix REMAP
3737

3838
// BRIDGE: /^test/objc.h:3:2: warning: warning in bridging header
3939
// BRIDGE-REMAP: BUILD_DIR{{.*}}{{/|\\}}objc.h:3:2: warning: warning in bridging header

test/CAS/dependency_file.swift

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
// RUN: %target-swift-frontend -scan-dependencies -module-name Test -module-cache-path %t/clang-module-cache -O \
3939
// RUN: -disable-implicit-string-processing-module-import -disable-implicit-concurrency-module-import -parse-stdlib \
4040
// RUN: %t/main.swift -o %t/deps-1.json -swift-version 5 -cache-compile-job -cas-path %t/cas -I %t/include -sdk %t/sdk \
41-
// RUN: -scanner-prefix-map %swift_src_root=/^src -scanner-prefix-map %t=/^tmp -scanner-prefix-map %t/sdk=/^sdk
41+
// RUN: -scanner-prefix-map-paths %swift_src_root /^src -scanner-prefix-map-paths %t /^tmp -scanner-prefix-map-paths %t/sdk /^sdk
4242
// RUN: %{python} %S/Inputs/BuildCommandExtractor.py %t/deps-1.json A > %t/A1.cmd
4343
// RUN: %swift_frontend_plain @%t/A1.cmd
4444
// RUN: %{python} %S/Inputs/GenerateExplicitModuleMap.py %t/deps-1.json > %t/map-1.json
@@ -50,7 +50,7 @@
5050
// RUN: -swift-version 5 -disable-implicit-swift-modules \
5151
// RUN: -disable-implicit-string-processing-module-import -disable-implicit-concurrency-module-import -parse-stdlib \
5252
// RUN: -module-name Test -explicit-swift-module-map-file @%t/map.casid \
53-
// RUN: -cache-replay-prefix-map /^src=%swift_src_root -cache-replay-prefix-map /^tmp=%t -cache-replay-prefix-map /^sdk=%t/sdk \
53+
// RUN: -cache-replay-prefix-map /^src %swift_src_root -cache-replay-prefix-map /^tmp %t -cache-replay-prefix-map /^sdk %t/sdk \
5454
// RUN: /^tmp/main.swift @%t/MyApp-1.cmd -emit-dependencies -emit-dependencies-path %t/main-3.d
5555

5656
// RUN: %FileCheck %s --check-prefix=DEPS3 --input-file=%t/main-3.d -DTMP=%t
@@ -63,7 +63,7 @@
6363
// RUN: -swift-version 5 -disable-implicit-swift-modules \
6464
// RUN: -disable-implicit-string-processing-module-import -disable-implicit-concurrency-module-import -parse-stdlib \
6565
// RUN: -module-name Test -explicit-swift-module-map-file @%t/map.casid \
66-
// RUN: -cache-replay-prefix-map /^src=%swift_src_root -cache-replay-prefix-map /^tmp=%t -cache-replay-prefix-map /^sdk=%t/sdk \
66+
// RUN: -cache-replay-prefix-map /^src %swift_src_root -cache-replay-prefix-map /^tmp %t -cache-replay-prefix-map /^sdk %t/sdk \
6767
// RUN: /^tmp/main.swift @%t/MyApp-1.cmd -emit-dependencies -emit-dependencies-path %t/main-4.d > %t/key.casid
6868

6969
// RUN: %swift-scan-test -action replay_result -cas-path %t/cas -id @%t/key.casid -- \
@@ -72,7 +72,7 @@
7272
// RUN: -swift-version 5 -disable-implicit-swift-modules \
7373
// RUN: -disable-implicit-string-processing-module-import -disable-implicit-concurrency-module-import -parse-stdlib \
7474
// RUN: -module-name Test -explicit-swift-module-map-file @%t/map.casid \
75-
// RUN: -cache-replay-prefix-map /^src=%swift_src_root -cache-replay-prefix-map /^tmp=%t -cache-replay-prefix-map /^sdk=%t/sdk \
75+
// RUN: -cache-replay-prefix-map /^src %swift_src_root -cache-replay-prefix-map /^tmp %t -cache-replay-prefix-map /^sdk %t/sdk \
7676
// RUN: /^tmp/main.swift @%t/MyApp-1.cmd -emit-dependencies -emit-dependencies-path %t/main-4.d 2>&1 | %FileCheck %s --check-prefix=CACHE-HIT4
7777
// CACHE-HIT4: remark: replay output file '{{.*}}{{/|\\}}main-4.d': key 'llvmcas://{{.*}}'
7878
// RUN: %FileCheck %s --check-prefix=DEPS4 --input-file=%t/main-4.d -DTMP=%t

test/CAS/macro_plugin_external.swift

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
// RUN: %target-swift-frontend -scan-dependencies -module-load-mode prefer-serialized -module-name MyApp -module-cache-path %t/clang-module-cache -O \
5151
// RUN: -disable-implicit-string-processing-module-import -disable-implicit-concurrency-module-import \
5252
// RUN: %t/macro.swift -o %t/deps2.json -swift-version 5 -cache-compile-job -cas-path %t/cas -external-plugin-path %t/plugins#%swift-plugin-server \
53-
// RUN: -scanner-prefix-map %t=/^test -scanner-prefix-map %swift-bin-dir=/^bin -resolved-plugin-verification
53+
// RUN: -scanner-prefix-map-paths %t /^test -scanner-prefix-map-paths %swift-bin-dir /^bin -resolved-plugin-verification
5454

5555
// RUN: %S/Inputs/SwiftDepsExtractor.py %t/deps2.json MyApp casFSRootID > %t/fs.casid
5656
// RUN: %cache-tool -cas-path %t/cas -cache-tool-action print-include-tree-list @%t/fs.casid | %FileCheck %s --check-prefix=FS-REMAP -DLIB=%target-library-name(MacroDefinition)
@@ -77,7 +77,7 @@
7777
// RUN: -swift-version 5 -disable-implicit-swift-modules -O \
7878
// RUN: -disable-implicit-string-processing-module-import -disable-implicit-concurrency-module-import \
7979
// RUN: -module-name MyApp -explicit-swift-module-map-file @%t/map2.casid -Rmacro-loading -Rcache-compile-job \
80-
// RUN: /^test/macro.swift @%t/MyApp2.cmd -cache-replay-prefix-map /^test=%t -cache-replay-prefix-map /^bin=%swift-bin-dir 2>&1 | %FileCheck %s --check-prefix=REMARK
80+
// RUN: /^test/macro.swift @%t/MyApp2.cmd -cache-replay-prefix-map /^test %t -cache-replay-prefix-map /^bin %swift-bin-dir 2>&1 | %FileCheck %s --check-prefix=REMARK
8181
// REMAKR: remark: cache miss
8282
// REMARK: remark: loaded macro implementation module 'MacroDefinition' from compiler plugin server
8383

@@ -92,7 +92,7 @@
9292
// RUN: -swift-version 5 -disable-implicit-swift-modules -O \
9393
// RUN: -disable-implicit-string-processing-module-import -disable-implicit-concurrency-module-import \
9494
// RUN: -module-name MyApp -explicit-swift-module-map-file @%t/map2.casid -Rmacro-loading -Rcache-compile-job \
95-
// RUN: /^test/macro.swift @%t/MyApp2.cmd -cache-replay-prefix-map /^test=%t -cache-replay-prefix-map /^bin=%swift-bin-dir 2>&1 | %FileCheck %s --check-prefix=NO-REMARK
95+
// RUN: /^test/macro.swift @%t/MyApp2.cmd -cache-replay-prefix-map /^test %t -cache-replay-prefix-map /^bin %swift-bin-dir 2>&1 | %FileCheck %s --check-prefix=NO-REMARK
9696
// NO-REMARK: remark: replay output file
9797
// NO-REMARK-NOT: remark: loaded macro implementation module 'MacroDefinition' from compiler plugin server
9898

@@ -103,7 +103,7 @@
103103
// RUN: -swift-version 5 -disable-implicit-swift-modules -O \
104104
// RUN: -disable-implicit-string-processing-module-import -disable-implicit-concurrency-module-import \
105105
// RUN: -module-name MyApp -explicit-swift-module-map-file @%t/map2.casid -Rmacro-loading -Rcache-compile-job -cache-disable-replay \
106-
// RUN: /^test/macro.swift @%t/MyApp2.cmd -cache-replay-prefix-map /^test=%t -cache-replay-prefix-map /^bin=%swift-bin-dir
106+
// RUN: /^test/macro.swift @%t/MyApp2.cmd -cache-replay-prefix-map /^test %t -cache-replay-prefix-map /^bin %swift-bin-dir
107107

108108
/// Change the dylib content, this will fail the build.
109109
// RUN: echo " " >> %t/plugins/%target-library-name(MacroDefinition)
@@ -112,7 +112,7 @@
112112
// RUN: -swift-version 5 -disable-implicit-swift-modules -O \
113113
// RUN: -disable-implicit-string-processing-module-import -disable-implicit-concurrency-module-import \
114114
// RUN: -module-name MyApp -explicit-swift-module-map-file @%t/map2.casid -Rmacro-loading -Rcache-compile-job -cache-disable-replay \
115-
// RUN: /^test/macro.swift @%t/MyApp2.cmd -cache-replay-prefix-map /^test=%t -cache-replay-prefix-map /^bin=%swift-bin-dir 2>&1 | %FileCheck %s --check-prefix=FAILED
115+
// RUN: /^test/macro.swift @%t/MyApp2.cmd -cache-replay-prefix-map /^test %t -cache-replay-prefix-map /^bin %swift-bin-dir 2>&1 | %FileCheck %s --check-prefix=FAILED
116116
// FAILED: plugin has changed since dependency scanning
117117

118118
//--- nomacro.swift

test/CAS/module_path_remap.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
// RUN: %target-swift-frontend -scan-dependencies -module-cache-path %t/clang-module-cache %s -o %t/deps.json \
88
// RUN: -I %S/../ScanDependencies/Inputs/CHeaders -I %S/../ScanDependencies/Inputs/Swift -emit-dependencies \
99
// RUN: -import-objc-header %S/../ScanDependencies/Inputs/CHeaders/Bridging.h -swift-version 4 -cache-compile-job \
10-
// RUN: -cas-path %t/cas -scanner-prefix-map %swift_src_root=/^src -scanner-prefix-map %t=/^tmp -scanner-output-dir %t -auto-bridging-header-chaining
10+
// RUN: -cas-path %t/cas -scanner-prefix-map-paths %swift_src_root /^src -scanner-prefix-map-paths %t /^tmp -scanner-output-dir %t -auto-bridging-header-chaining
1111

1212
// RUN: %{python} %S/Inputs/SwiftDepsExtractor.py %t/deps.json deps casFSRootID > %t/deps.fs.casid
1313
// RUN: %cache-tool -cas-path %t/cas -cache-tool-action print-include-tree-list @%t/deps.fs.casid | %FileCheck %s -check-prefix DEPS-FS

test/CAS/path_remap.swift

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
// RUN: %target-swift-frontend -scan-dependencies -module-name Test -module-cache-path %t/clang-module-cache -O \
55
// RUN: -disable-implicit-string-processing-module-import -disable-implicit-concurrency-module-import -parse-stdlib \
66
// RUN: %t/main.swift -o %t/deps.json -swift-version 5 -cache-compile-job -cas-path %t/cas -I %t/include -sdk %t/sdk \
7-
// RUN: -scanner-prefix-map %swift_src_root=/^src -scanner-prefix-map %t=/^tmp -scanner-prefix-map %t/sdk=/^sdk -enable-cross-import-overlays
7+
// RUN: -scanner-prefix-map-paths %swift_src_root /^src -scanner-prefix-map-paths %t /^tmp -scanner-prefix-map-paths %t/sdk /^sdk -enable-cross-import-overlays
88

99
// RUN: %{python} %S/Inputs/BuildCommandExtractor.py %t/deps.json A > %t/A.cmd
1010
// RUN: %swift_frontend_plain @%t/A.cmd
@@ -32,7 +32,7 @@
3232
// RUN: -swift-version 5 -disable-implicit-swift-modules \
3333
// RUN: -disable-implicit-string-processing-module-import -disable-implicit-concurrency-module-import -parse-stdlib \
3434
// RUN: -module-name Test -explicit-swift-module-map-file @%t/map.casid \
35-
// RUN: -cache-replay-prefix-map /^src=%swift_src_root -cache-replay-prefix-map /^tmp=%t -cache-replay-prefix-map /^sdk=%t/sdk \
35+
// RUN: -cache-replay-prefix-map /^src %swift_src_root -cache-replay-prefix-map /^tmp %t -cache-replay-prefix-map /^sdk %t/sdk \
3636
// RUN: /^tmp/main.swift @%t/MyApp.cmd -enable-cross-import-overlays
3737

3838
// RUN: %swift-scan-test -action compute_cache_key_from_index -cas-path %t/cas -input 0 -- \
@@ -41,7 +41,7 @@
4141
// RUN: -swift-version 5 -disable-implicit-swift-modules \
4242
// RUN: -disable-implicit-string-processing-module-import -disable-implicit-concurrency-module-import -parse-stdlib \
4343
// RUN: -module-name Test -explicit-swift-module-map-file @%t/map.casid \
44-
// RUN: -cache-replay-prefix-map /^src=%swift_src_root -cache-replay-prefix-map /^tmp=%t -cache-replay-prefix-map /^sdk=%t/sdk \
44+
// RUN: -cache-replay-prefix-map /^src %swift_src_root -cache-replay-prefix-map /^tmp %t -cache-replay-prefix-map /^sdk %t/sdk \
4545
// RUN: /^tmp/main.swift @%t/MyApp.cmd -enable-cross-import-overlays > %t/key.casid
4646

4747
// RUN: %swift-scan-test -action replay_result -cas-path %t/cas -id @%t/key.casid -- \
@@ -50,7 +50,7 @@
5050
// RUN: -swift-version 5 -disable-implicit-swift-modules \
5151
// RUN: -disable-implicit-string-processing-module-import -disable-implicit-concurrency-module-import -parse-stdlib \
5252
// RUN: -module-name Test -explicit-swift-module-map-file @%t/map.casid \
53-
// RUN: -cache-replay-prefix-map /^src=%swift_src_root -cache-replay-prefix-map /^tmp=%t -cache-replay-prefix-map /^sdk=%t/sdk \
53+
// RUN: -cache-replay-prefix-map /^src %swift_src_root -cache-replay-prefix-map /^tmp %t -cache-replay-prefix-map /^sdk %t/sdk \
5454
// RUN: /^tmp/main.swift @%t/MyApp.cmd -enable-cross-import-overlays
5555

5656
//--- main.swift

test/CAS/simlink_inputs.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
/// Test the same build but remapping the path.
2727
// RUN: %target-swift-frontend -scan-dependencies -module-name Test -module-cache-path %t/clang-module-cache -O \
2828
// RUN: -disable-implicit-string-processing-module-import -disable-implicit-concurrency-module-import -parse-stdlib \
29-
// RUN: -scanner-prefix-map %swift_src_root=/^src -scanner-prefix-map %t/src=/^tmp -scanner-prefix-map %t/sdk=/^sdk \
29+
// RUN: -scanner-prefix-map-paths %swift_src_root /^src -scanner-prefix-map-paths %t/src /^tmp -scanner-prefix-map-paths %t/sdk /^sdk \
3030
// RUN: %t/src/main.swift -o %t/deps-1.json -swift-version 5 -cache-compile-job -cas-path %t/cas -I %t/src/include
3131

3232
// RUN: %{python} %S/Inputs/BuildCommandExtractor.py %t/deps-1.json clang:A > %t/A-1.cmd
@@ -42,7 +42,7 @@
4242
// RUN: -swift-version 5 -disable-implicit-swift-modules \
4343
// RUN: -disable-implicit-string-processing-module-import -disable-implicit-concurrency-module-import -parse-stdlib \
4444
// RUN: -module-name Test -explicit-swift-module-map-file @%t/map-1.casid \
45-
// RUN: -cache-replay-prefix-map /^src=%swift_src_root -cache-replay-prefix-map /^tmp=%t/src -cache-replay-prefix-map /^sdk=%t/sdk \
45+
// RUN: -cache-replay-prefix-map /^src %swift_src_root -cache-replay-prefix-map /^tmp %t/src -cache-replay-prefix-map /^sdk %t/sdk \
4646
// RUN: /^tmp/main.swift @%t/MyApp-1.cmd
4747

4848
//--- private/main.swift

utils/dev-scripts/split-cmdline

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -288,6 +288,7 @@ def main():
288288
"-scanner-prefix-map",
289289
"-scanner-prefix-map-sdk",
290290
"-scanner-prefix-map-toolchain",
291+
"-scanner-prefix-map-paths",
291292
"-sdk",
292293
"-serialize-breaking-changes-path",
293294
"-serialize-diagnostics",

0 commit comments

Comments
 (0)