Skip to content

Commit ba68faa

Browse files
committed
[test] Mark tests that use experimental/upcoming features as such
Find all the usages of `--enable-experimental-feature` or `--enable-upcoming-feature` in the tests and replace some of the `REQUIRES: asserts` to use `REQUIRES: swift-feature-Foo` instead, which should correctly apply to depending on the asserts/noasserts mode of the toolchain for each feature. Remove some comments that talked about enabling asserts since they don't apply anymore (but I might had miss some). All this was done with an automated script, so some formatting weirdness might happen, but I hope I fixed most of those. There might be some tests that were `REQUIRES: asserts` that might run in `noasserts` toolchains now. This will normally be because their feature went from experimental to upcoming/base and the tests were not updated.
1 parent facdb57 commit ba68faa

File tree

727 files changed

+1047
-297
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

727 files changed

+1047
-297
lines changed

test/ASTGen/attrs.swift

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,8 @@
1212

1313
// REQUIRES: executable_test
1414
// REQUIRES: swift_swift_parser
15+
// REQUIRES: swift_feature_ParserASTGen
1516

16-
// -enable-experimental-feature requires an asserts build
17-
// REQUIRES: asserts
1817
// rdar://116686158
1918
// UNSUPPORTED: asan
2019

test/ASTGen/decls.swift

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,10 @@
1313

1414
// REQUIRES: executable_test
1515
// REQUIRES: swift_swift_parser
16+
// REQUIRES: swift_feature_ParserASTGen
17+
// REQUIRES: swift_feature_SwiftParser
18+
// REQUIRES: swift_feature_ValueGenerics
1619

17-
// -enable-experimental-feature requires an asserts build
18-
// REQUIRES: asserts
1920
// rdar://116686158
2021
// UNSUPPORTED: asan
2122

test/ASTGen/diagnostics.swift

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,7 @@
1212
// RUN: %target-typecheck-verify-swift -disable-availability-checking -enable-bare-slash-regex -enable-experimental-feature ParserASTGen
1313

1414
// REQUIRES: swift_swift_parser
15-
// -enable-experimental-feature requires an asserts build
16-
// REQUIRES: asserts
15+
// REQUIRES: swift_feature_ParserASTGen
1716
// rdar://116686158
1817
// UNSUPPORTED: asan
1918

test/ASTGen/do_expr.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
// RUN: %target-typecheck-verify-swift -disable-availability-checking -enable-experimental-feature DoExpressions -enable-experimental-feature ParserASTGen
1313

1414
// REQUIRES: swift_swift_parser
15-
// -enable-experimental-feature requires an asserts build
16-
// REQUIRES: asserts
15+
// REQUIRES: swift_feature_DoExpressions
16+
// REQUIRES: swift_feature_ParserASTGen
1717
// rdar://116686158
1818
// UNSUPPORTED: asan
1919

test/ASTGen/exprs.swift

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

1414
// REQUIRES: executable_test
1515
// REQUIRES: swift_swift_parser
16+
// REQUIRES: swift_feature_ParserASTGen
17+
// REQUIRES: swift_feature_SwiftParser
1618

17-
// -enable-experimental-feature requires an asserts build
18-
// REQUIRES: asserts
1919
// rdar://116686158
2020
// UNSUPPORTED: asan
2121

test/ASTGen/if_config.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// RUN: %target-typecheck-verify-swift -enable-experimental-feature ParserASTGen -DDISCARDABLE -DNONSENDABLE -swift-version 6
2-
/// -enable-experimental-feature requires an asserts build
3-
// REQUIRES: asserts
2+
3+
// REQUIRES: swift_feature_ParserASTGen
44

55
#if NOT_SET
66
func f { } // expected-error{{expected parameter clause in function signature}}

test/ASTGen/if_config_expr.swift

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
// RUN: %target-typecheck-verify-swift -enable-experimental-feature ParserASTGen -D CONDITION_1
22

3-
// -enable-experimental-feature requires an asserts build
4-
// REQUIRES: asserts
53
// REQUIRES: swift_swift_parser
4+
// REQUIRES: swift_feature_ParserASTGen
65

76
postfix operator ++
87
postfix func ++ (_: Int) -> Int { 0 }

test/ASTGen/macros.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
// REQUIRES: swift_swift_parser, asserts
2+
// REQUIRES: swift_feature_ParserASTGen
23

34
// RUN: %empty-directory(%t)
45

test/ASTGen/regex.swift

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,8 @@
1111
// RUN: %target-typecheck-verify-swift -enable-experimental-feature ParserASTGen -enable-bare-slash-regex -disable-availability-checking
1212

1313
// REQUIRES: swift_swift_parser
14+
// REQUIRES: swift_feature_ParserASTGen
1415

15-
// -enable-experimental-feature requires an asserts build
16-
// REQUIRES: asserts
1716
// rdar://116686158
1817
// UNSUPPORTED: asan
1918

test/ASTGen/stmts.swift

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,10 @@
1212

1313
// REQUIRES: executable_test
1414
// REQUIRES: swift_swift_parser
15+
// REQUIRES: swift_feature_ParserASTGen
16+
// REQUIRES: swift_feature_SwiftParser
17+
// REQUIRES: swift_feature_ThenStatements
1518

16-
// -enable-experimental-feature requires an asserts build
17-
// REQUIRES: asserts
1819
// rdar://116686158
1920
// UNSUPPORTED: asan
2021

0 commit comments

Comments
 (0)