Skip to content

Commit 94306b0

Browse files
committed
Tests: Limit the attr_backDeploy_evolution.swift test case to running on macOS and hard code all availability versions it uses. I had hoped to get broader coverage with this test but that goal appears to be unrealistic given the variety of test bot configurations that this test is sensitive to. Hopefully this simplification will prevent further discoveries of incompatible test bot configurations.
Resolves rdar://91181116
1 parent 19ebc9b commit 94306b0

File tree

1 file changed

+16
-23
lines changed

1 file changed

+16
-23
lines changed

test/attr/attr_backDeploy_evolution.swift

Lines changed: 16 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -30,14 +30,7 @@
3030
//
3131

3232
// REQUIRES: executable_test
33-
// REQUIRES: VENDOR=apple
34-
35-
// This test doesn't behave as expected on some deployment targets because
36-
// the minimum OS versions accepted by the linker are later than the deployment
37-
// targets given to the compiler invocation, and therefore symbols that need
38-
// to be weak linked for the test to function are not.
39-
// UNSUPPORTED: OS=ios && CPU=arm64e
40-
// UNSUPPORTED: OS=watchos && CPU=x86_64
33+
// REQUIRES: OS=macosx
4134

4235
// ---- (0) Prepare SDK
4336
// RUN: %empty-directory(%t)
@@ -49,21 +42,21 @@
4942
// RUN: %target-build-swift-dylib(%t/SDK_ABI/Frameworks/BackDeployHelper.framework/BackDeployHelper) \
5043
// RUN: -emit-module-path %t/SDK_ABI/Frameworks/BackDeployHelper.framework/Modules/BackDeployHelper.swiftmodule/%module-target-triple.swiftmodule \
5144
// RUN: -module-name BackDeployHelper -emit-module %S/Inputs/BackDeployHelper.swift \
52-
// RUN: -Xfrontend -target -Xfrontend %target-next-stable-abi-triple \
45+
// RUN: -target %target-cpu-apple-macosx10.15 \
5346
// RUN: -Xfrontend -define-availability \
54-
// RUN: -Xfrontend 'BackDeploy 1.0:macOS 10.14.3, iOS 12.1, tvOS 12.1, watchOS 5.1' \
47+
// RUN: -Xfrontend 'BackDeploy 1.0:macOS 10.14.3' \
5548
// RUN: -Xfrontend -define-availability \
56-
// RUN: -Xfrontend 'BackDeploy 2.0:macOS 10.15, iOS 13, tvOS 13, watchOS 6' \
49+
// RUN: -Xfrontend 'BackDeploy 2.0:macOS 10.15' \
5750
// RUN: -Xlinker -install_name -Xlinker @rpath/BackDeployHelper.framework/BackDeployHelper \
5851
// RUN: -enable-library-evolution
5952

6053
// ---- (2) Build executable
6154
// RUN: %target-build-swift -emit-executable %s -g -o %t/test_ABI \
62-
// RUN: -Xfrontend -target -Xfrontend %target-pre-stable-abi-triple \
55+
// RUN: -target %target-cpu-apple-macosx10.14.3 \
6356
// RUN: -Xfrontend -define-availability \
64-
// RUN: -Xfrontend 'BackDeploy 1.0:macOS 10.14.3, iOS 12.1, tvOS 12.1, watchOS 5.1' \
57+
// RUN: -Xfrontend 'BackDeploy 1.0:macOS 10.14.3' \
6558
// RUN: -Xfrontend -define-availability \
66-
// RUN: -Xfrontend 'BackDeploy 2.0:macOS 10.15, iOS 13, tvOS 13, watchOS 6' \
59+
// RUN: -Xfrontend 'BackDeploy 2.0:macOS 10.15' \
6760
// RUN: -F %t/SDK_ABI/Frameworks/ -framework BackDeployHelper \
6861
// RUN: %target-rpath(@executable_path/SDK_ABI/Frameworks)
6962

@@ -76,21 +69,21 @@
7669
// RUN: %target-build-swift-dylib(%t/SDK_BD/Frameworks/BackDeployHelper.framework/BackDeployHelper) \
7770
// RUN: -emit-module-path %t/SDK_BD/Frameworks/BackDeployHelper.framework/Modules/BackDeployHelper.swiftmodule/%module-target-triple.swiftmodule \
7871
// RUN: -module-name BackDeployHelper -emit-module %S/Inputs/BackDeployHelper.swift \
79-
// RUN: -Xfrontend -target -Xfrontend %target-next-stable-abi-triple \
72+
// RUN: -target %target-cpu-apple-macosx10.15 \
8073
// RUN: -Xfrontend -define-availability \
81-
// RUN: -Xfrontend 'BackDeploy 1.0:macOS 10.14.3, iOS 12.1, tvOS 12.1, watchOS 5.1' \
74+
// RUN: -Xfrontend 'BackDeploy 1.0:macOS 10.14.3' \
8275
// RUN: -Xfrontend -define-availability \
83-
// RUN: -Xfrontend 'BackDeploy 2.0:macOS 999.0, iOS 999.0, watchOS 999.0, tvOS 999.0' \
76+
// RUN: -Xfrontend 'BackDeploy 2.0:macOS 999.0' \
8477
// RUN: -Xlinker -install_name -Xlinker @rpath/BackDeployHelper.framework/BackDeployHelper \
8578
// RUN: -enable-library-evolution
8679

8780
// ---- (5) Build executable
8881
// RUN: %target-build-swift -emit-executable %s -g -o %t/test_BD \
89-
// RUN: -Xfrontend -target -Xfrontend %target-next-stable-abi-triple \
82+
// RUN: -target %target-cpu-apple-macosx10.14.3 \
9083
// RUN: -Xfrontend -define-availability \
91-
// RUN: -Xfrontend 'BackDeploy 1.0:macOS 10.14.3, iOS 12.1, tvOS 12.1, watchOS 5.1' \
84+
// RUN: -Xfrontend 'BackDeploy 1.0:macOS 10.14.3' \
9285
// RUN: -Xfrontend -define-availability \
93-
// RUN: -Xfrontend 'BackDeploy 2.0:macOS 999.0, iOS 999.0, watchOS 999.0, tvOS 999.0' \
86+
// RUN: -Xfrontend 'BackDeploy 2.0:macOS 999.0' \
9487
// RUN: -F %t/SDK_BD/Frameworks/ -framework BackDeployHelper \
9588
// RUN: %target-rpath(@executable_path/SDK_BD/Frameworks)
9689

@@ -103,11 +96,11 @@
10396
// RUN: %target-build-swift-dylib(%t/SDK_BD/Frameworks/BackDeployHelper.framework/BackDeployHelper) \
10497
// RUN: -emit-module-path %t/SDK_BD/Frameworks/BackDeployHelper.framework/Modules/BackDeployHelper.swiftmodule/%module-target-triple.swiftmodule \
10598
// RUN: -module-name BackDeployHelper -emit-module %S/Inputs/BackDeployHelper.swift \
106-
// RUN: -Xfrontend -target -Xfrontend %target-next-stable-abi-triple \
99+
// RUN: -target %target-cpu-apple-macosx10.15 \
107100
// RUN: -Xfrontend -define-availability \
108-
// RUN: -Xfrontend 'BackDeploy 1.0:macOS 10.14.3, iOS 12.1, tvOS 12.1, watchOS 5.1' \
101+
// RUN: -Xfrontend 'BackDeploy 1.0:macOS 10.14.3' \
109102
// RUN: -Xfrontend -define-availability \
110-
// RUN: -Xfrontend 'BackDeploy 2.0:macOS 999.0, iOS 999.0, watchOS 999.0, tvOS 999.0' \
103+
// RUN: -Xfrontend 'BackDeploy 2.0:macOS 999.0' \
111104
// RUN: -Xlinker -install_name -Xlinker @rpath/BackDeployHelper.framework/BackDeployHelper \
112105
// RUN: -enable-library-evolution -DSTRIP_V2_APIS
113106

0 commit comments

Comments
 (0)