|
8 | 8 | // See https://swift.org/CONTRIBUTORS.txt for Swift project authors |
9 | 9 | // |
10 | 10 |
|
| 11 | +private import _TestingInternals |
| 12 | + |
11 | 13 | /// A type that defines a time limit to apply to a test. |
12 | 14 | /// |
13 | 15 | /// To add this trait to a test, use ``Trait/timeLimit(_:)-4kzjp``. |
@@ -126,55 +128,55 @@ extension TimeLimitTrait.Duration { |
126 | 128 | /// This function is unavailable and is provided for diagnostic purposes only. |
127 | 129 | @available(*, unavailable, message: "Time limit must be specified in minutes") |
128 | 130 | public static func seconds(_ seconds: some BinaryInteger) -> Self { |
129 | | - fatalError("Unsupported") |
| 131 | + swt_unreachable() |
130 | 132 | } |
131 | 133 |
|
132 | 134 | /// Construct a time limit duration given a number of seconds. |
133 | 135 | /// |
134 | 136 | /// This function is unavailable and is provided for diagnostic purposes only. |
135 | 137 | @available(*, unavailable, message: "Time limit must be specified in minutes") |
136 | 138 | public static func seconds(_ seconds: Double) -> Self { |
137 | | - fatalError("Unsupported") |
| 139 | + swt_unreachable() |
138 | 140 | } |
139 | 141 |
|
140 | 142 | /// Construct a time limit duration given a number of milliseconds. |
141 | 143 | /// |
142 | 144 | /// This function is unavailable and is provided for diagnostic purposes only. |
143 | 145 | @available(*, unavailable, message: "Time limit must be specified in minutes") |
144 | 146 | public static func milliseconds(_ milliseconds: some BinaryInteger) -> Self { |
145 | | - fatalError("Unsupported") |
| 147 | + swt_unreachable() |
146 | 148 | } |
147 | 149 |
|
148 | 150 | /// Construct a time limit duration given a number of milliseconds. |
149 | 151 | /// |
150 | 152 | /// This function is unavailable and is provided for diagnostic purposes only. |
151 | 153 | @available(*, unavailable, message: "Time limit must be specified in minutes") |
152 | 154 | public static func milliseconds(_ milliseconds: Double) -> Self { |
153 | | - fatalError("Unsupported") |
| 155 | + swt_unreachable() |
154 | 156 | } |
155 | 157 |
|
156 | 158 | /// Construct a time limit duration given a number of microseconds. |
157 | 159 | /// |
158 | 160 | /// This function is unavailable and is provided for diagnostic purposes only. |
159 | 161 | @available(*, unavailable, message: "Time limit must be specified in minutes") |
160 | 162 | public static func microseconds(_ microseconds: some BinaryInteger) -> Self { |
161 | | - fatalError("Unsupported") |
| 163 | + swt_unreachable() |
162 | 164 | } |
163 | 165 |
|
164 | 166 | /// Construct a time limit duration given a number of microseconds. |
165 | 167 | /// |
166 | 168 | /// This function is unavailable and is provided for diagnostic purposes only. |
167 | 169 | @available(*, unavailable, message: "Time limit must be specified in minutes") |
168 | 170 | public static func microseconds(_ microseconds: Double) -> Self { |
169 | | - fatalError("Unsupported") |
| 171 | + swt_unreachable() |
170 | 172 | } |
171 | 173 |
|
172 | 174 | /// Construct a time limit duration given a number of nanoseconds. |
173 | 175 | /// |
174 | 176 | /// This function is unavailable and is provided for diagnostic purposes only. |
175 | 177 | @available(*, unavailable, message: "Time limit must be specified in minutes") |
176 | 178 | public static func nanoseconds(_ nanoseconds: some BinaryInteger) -> Self { |
177 | | - fatalError("Unsupported") |
| 179 | + swt_unreachable() |
178 | 180 | } |
179 | 181 | } |
180 | 182 |
|
|
0 commit comments