Skip to content

Commit a8c785b

Browse files
committed
[test] Update & reenable stdlib ABI stability tests
1 parent 5e9934c commit a8c785b

7 files changed

+74
-36
lines changed

test/api-digester/Outputs/stability-stdlib-abi.asserts.additional.swift.expected

Lines changed: 0 additions & 7 deletions
This file was deleted.

test/api-digester/Outputs/stability-stdlib-abi.without.asserts.swift.expected

Lines changed: 0 additions & 1 deletion
This file was deleted.

test/api-digester/lit.local.cfg

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
config.suffixes.add('.test')

test/api-digester/stability-stdlib-abi-with-asserts.swift

Lines changed: 0 additions & 15 deletions
This file was deleted.
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
// Welcome, Build Wrangler!
2+
//
3+
// A failure in this test indicates that there is a potential ABI breaking
4+
// change in the Standard Library. If you observe a failure, please reach out to
5+
// the Standard Library team directly to make sure we resolve this quickly!
6+
//
7+
// Instead of XFAILing this test, please consider extending the list of expected
8+
// changes at the bottom. (In addition to ignoring the current set of ABI breaks,
9+
// XFAILing this test also silences any future ABI breaks that may land on this
10+
// branch, which isn't ideal.)
11+
//
12+
// You can find a diff of what needs to be added in the output of the failed
13+
// test run. The order of lines doesn't matter, and you can also include
14+
// comments to refer to any bugs you filed.
15+
//
16+
// Thanks! -- Your friendly stdlib engineers
17+
18+
// REQUIRES: OS=macosx
19+
// REQUIRES: swift_stdlib_asserts
20+
// RUN: %empty-directory(%t.tmp)
21+
// mkdir %t.tmp/module-cache && mkdir %t.tmp/dummy.sdk
22+
// RUN: %api-digester -diagnose-sdk -module Swift -o %t.tmp/changes.txt -module-cache-path %t.tmp/module-cache -sdk %t.tmp/dummy.sdk -abi -avoid-location
23+
// RUN: %clang -E -P -x c %S/stability-stdlib-abi-without-asserts.test -o - > %t.tmp/stability-stdlib-abi.swift.expected
24+
// RUN: %clang -E -P -x c %S/stability-stdlib-abi-with-asserts.test -o - >> %t.tmp/stability-stdlib-abi.swift.expected
25+
// RUN: %clang -E -P -x c %t.tmp/stability-stdlib-abi.swift.expected -o - | sed '/^\s*$/d' | sort > %t.tmp/stability-stdlib-abi.swift.expected.sorted
26+
// RUN: %clang -E -P -x c %t.tmp/changes.txt -o - | sed '/^\s*$/d' | sort > %t.tmp/changes.txt.tmp
27+
// RUN: diff -u %t.tmp/stability-stdlib-abi.swift.expected.sorted %t.tmp/changes.txt.tmp
28+
29+
// The digester can incorrectly register a generic signature change when
30+
// declarations are shuffled. rdar://problem/46618883
31+
// UNSUPPORTED: swift_evolve
32+
33+
Func _collectReferencesInsideObject(_:) is a new API without @available attribute
34+
Func _loadDestroyTLSCounter() is a new API without @available attribute
35+
Func _measureRuntimeFunctionCountersDiffs(objects:_:) is a new API without @available attribute
36+
Protocol _RuntimeFunctionCountersStats is a new API without @available attribute
37+
Struct _GlobalRuntimeFunctionCountersState is a new API without @available attribute
38+
Struct _ObjectRuntimeFunctionCountersState is a new API without @available attribute
39+
Struct _RuntimeFunctionCounters is a new API without @available attribute
40+
Func _swift_isImmutableCOWBuffer(_:) is a new API without @available attribute
41+
Func _swift_setImmutableCOWBuffer(_:_:) is a new API without @available attribute

test/api-digester/stability-stdlib-abi-without-asserts.swift

Lines changed: 0 additions & 13 deletions
This file was deleted.
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
// Welcome, Build Wrangler!
2+
//
3+
// A failure in this test indicates that there is a potential ABI breaking
4+
// change in the Standard Library. If you observe a failure, please reach out to
5+
// the Standard Library team directly to make sure we resolve this quickly!
6+
//
7+
// Instead of XFAILing this test, please consider extending the list of expected
8+
// changes at the bottom. (In addition to ignoring the current set of ABI breaks,
9+
// XFAILing this test also silences any future ABI breaks that may land on this
10+
// branch, which isn't ideal.)
11+
//
12+
// You can find a diff of what needs to be added in the output of the failed
13+
// test run. The order of lines doesn't matter, and you can also include
14+
// comments to refer to any bugs you filed.
15+
//
16+
// Thanks! -- Your friendly stdlib engineers
17+
18+
// REQUIRES: OS=macosx
19+
// REQUIRES: swift_stdlib_no_asserts
20+
// RUN: %empty-directory(%t.tmp)
21+
// mkdir %t.tmp/module-cache && mkdir %t.tmp/dummy.sdk
22+
// RUN: %api-digester -diagnose-sdk -module Swift -o %t.tmp/changes.txt -module-cache-path %t.tmp/module-cache -sdk %t.tmp/dummy.sdk -abi -avoid-location -v
23+
// RUN: %clang -E -P -x c %S/stability-stdlib-abi-without-asserts.test -o - | sed '/^\s*$/d' | sort > %t.tmp/stability-stdlib-abi.swift.expected
24+
// RUN: %clang -E -P -x c %t.tmp/changes.txt -o - | sed '/^\s*$/d' | sort > %t.tmp/changes.txt.tmp
25+
// RUN: diff -u %t.tmp/stability-stdlib-abi.swift.expected %t.tmp/changes.txt.tmp
26+
27+
// The digester can incorrectly register a generic signature change when
28+
// declarations are shuffled. rdar://problem/46618883
29+
// UNSUPPORTED: swift_evolve
30+
31+
Func _prespecialize() is a new API without @available attribute
32+
Func _stdlib_isOSVersionAtLeastOrVariantVersionAtLeast(_:_:_:_:_:_:) is a new API without @available attribute

0 commit comments

Comments
 (0)