Skip to content

Commit c05b3e4

Browse files
committed
Tests: Adopt -experimental-lazy-typecheck in tests.
Also, restructure the `CHECK:` lines for the `-emit-tbd` test. The number of columns in the `.tbd` file appears to be variable, so we can't assume a layout for the symbols in the YAML.
1 parent 54435ac commit c05b3e4

File tree

3 files changed

+24
-6
lines changed

3 files changed

+24
-6
lines changed

test/Driver/emit-interface.swift

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,3 +26,9 @@
2626
// CHECK-FILELIST: swift{{(-frontend|c)?(\.exe)?"?}} -frontend
2727
// CHECK-FILELIST-SAME: -supplementary-output-file-map
2828
// CHECK-FILELIST-NOT: emit-interface.swift{{ }}
29+
30+
// RUN: %swiftc_driver -driver-print-jobs -target x86_64-apple-macosx10.9 -experimental-lazy-typecheck %s -emit-module-interface -o %t/foo 2>&1 | %FileCheck -check-prefix=CHECK-LAZY-TYPECHECK %s
31+
32+
// CHECK-LAZY-TYPECHECK: swift{{(-frontend|c)?(\.exe)?"?}} -frontend
33+
// CHECK-LAZY-TYPECHECK-SAME: -experimental-lazy-typecheck
34+
// CHECK-LAZY-TYPECHECK-SAME: emit-interface.swift

test/ModuleInterface/resolve-imports.swift renamed to test/ModuleInterface/lazy-typecheck.swift

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
// RUN: %empty-directory(%t)
22

33
// RUN: %target-swift-frontend -resolve-imports %s -emit-module-interface-path %t/main.swiftinterface -enable-library-evolution
4+
// RUN: %target-swift-frontend -experimental-lazy-typecheck %s -emit-module-interface-path %t/main.swiftinterface -enable-library-evolution
45
// RUN: %FileCheck %s < %t/main.swiftinterface
56

67
// CHECK: import Swift
@@ -22,4 +23,4 @@ public class C {}
2223
// CHECK: }
2324

2425
// Globals
25-
public var year = 2023
26+
public var year = 2023

test/TBD/resolve_imports.swift renamed to test/TBD/lazy_typecheck.swift

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
// RUN: %empty-directory(%t)
22
// RUN: %target-swift-frontend -resolve-imports -emit-tbd -emit-tbd-path %t/resolve_imports.tbd %s -disable-availability-checking
3+
// RUN: %target-swift-frontend -experimental-lazy-typecheck -emit-tbd -emit-tbd-path %t/lazy_typecheck.tbd %s -disable-availability-checking
34
// RUN: %FileCheck %s < %t/resolve_imports.tbd
5+
// RUN: %FileCheck %s < %t/lazy_typecheck.tbd
46

57
// REQUIRES: OS=macosx
68

@@ -27,8 +29,17 @@ extension PrivateProto {
2729

2830
public struct S: PrivateProto {}
2931

30-
// CHECK: symbols: [ '_$s15resolve_imports1CCMa', '_$s15resolve_imports1CCMm',
31-
// CHECK-NEXT: '_$s15resolve_imports1CCMn', '_$s15resolve_imports1CCN', '_$s15resolve_imports1CCfD',
32-
// CHECK-NEXT: '_$s15resolve_imports1CCfd', '_$s15resolve_imports1SVMa',
33-
// CHECK-NEXT: '_$s15resolve_imports1SVMn', '_$s15resolve_imports1SVN', '_$s15resolve_imports1SVSQAAMc',
34-
// CHECK-NEXT: '_$s15resolve_imports1SVSQAASQ2eeoiySbx_xtFZTW', _main ]
32+
// CHECK: symbols: [
33+
// CHECK: '_$s14lazy_typecheck1CCMa',
34+
// CHECK: '_$s14lazy_typecheck1CCMm',
35+
// CHECK: '_$s14lazy_typecheck1CCMn',
36+
// CHECK: '_$s14lazy_typecheck1CCN',
37+
// CHECK: '_$s14lazy_typecheck1CCfD',
38+
// CHECK: '_$s14lazy_typecheck1CCfd',
39+
// CHECK: '_$s14lazy_typecheck1SVMa',
40+
// CHECK: '_$s14lazy_typecheck1SVMn',
41+
// CHECK: '_$s14lazy_typecheck1SVN',
42+
// CHECK: '_$s14lazy_typecheck1SVSQAAMc',
43+
// CHECK: '_$s14lazy_typecheck1SVSQAASQ2eeoiySbx_xtFZTW',
44+
// CHECK: _main
45+
// CHECK: ]

0 commit comments

Comments
 (0)