Skip to content

Commit aa50afd

Browse files
committed
Update docs
1 parent ac3b055 commit aa50afd

File tree

3 files changed

+17
-13
lines changed

3 files changed

+17
-13
lines changed

Sources/Testing/ExitTests/ExitCondition.swift

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@ private import _TestingInternals
1313
/// An enumeration describing possible conditions under which a process will
1414
/// exit.
1515
///
16-
/// Values of this type are used to describe the conditions under which an exit
17-
/// test is expected to pass or fail by passing them to
18-
/// ``expect(exitsWith:_:sourceLocation:performing:)`` or
19-
/// ``require(exitsWith:_:sourceLocation:performing:)``.
16+
/// Values of this type can be passed to
17+
/// ``expect(exitsWith:observing:_:sourceLocation:performing:)`` or
18+
/// ``require(exitsWith:observing:_:sourceLocation:performing:)`` to configure
19+
/// which exit statuses should be considered successful.
2020
@_spi(Experimental)
2121
#if SWT_NO_PROCESS_SPAWNING
2222
@available(*, unavailable, message: "Exit tests are not available on this platform.")

Sources/Testing/ExitTests/ExitTest.swift

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -307,11 +307,15 @@ extension ExitTest {
307307
/// the exit test.
308308
///
309309
/// This handler is invoked when an exit test (i.e. a call to either
310-
/// ``expect(exitsWith:_:sourceLocation:performing:)`` or
311-
/// ``require(exitsWith:_:sourceLocation:performing:)``) is started. The
312-
/// handler is responsible for initializing a new child environment (typically
313-
/// a child process) and running the exit test identified by `sourceLocation`
314-
/// there. The exit test's body can be found using ``ExitTest/find(at:)``.
310+
/// ``expect(exitsWith:observing:_:sourceLocation:performing:)`` or
311+
/// ``require(exitsWith:observing:_:sourceLocation:performing:)``) is started.
312+
/// The handler is responsible for initializing a new child environment
313+
/// (typically a child process) and running the exit test identified by
314+
/// `sourceLocation` there.
315+
///
316+
/// In the child environment, you can find the exit test again using
317+
/// ``ExitTest/find(at:)`` and can be run by calling
318+
/// ``ExitTest/callAsFunction()``.
315319
///
316320
/// The parent environment should suspend until the results of the exit test
317321
/// are available or the child environment is otherwise terminated. The parent

Sources/Testing/ExitTests/ExitTestArtifacts.swift

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,8 @@ public struct ExitTestArtifacts: Sendable {
4949
///
5050
/// To enable gathering output from the standard output stream during an
5151
/// exit test, pass `\.standardOutputContent` in the `observedValues`
52-
/// argument of ``expect(exitsWith:_:sourceLocation:performing:)`` or
53-
/// ``require(exitsWith:_:sourceLocation:performing:)``.
52+
/// argument of ``expect(exitsWith:observing:_:sourceLocation:performing:)``
53+
/// or ``require(exitsWith:observing:_:sourceLocation:performing:)``.
5454
///
5555
/// If the exit test could not be started or if you did not request standard
5656
/// output content, the value of this property is the empty array.
@@ -75,8 +75,8 @@ public struct ExitTestArtifacts: Sendable {
7575
///
7676
/// To enable gathering output from the standard error stream during an exit
7777
/// test, pass `\.standardErrorContent` in the `observedValues` argument of
78-
/// ``expect(exitsWith:_:sourceLocation:performing:)`` or
79-
/// ``require(exitsWith:_:sourceLocation:performing:)``.
78+
/// ``expect(exitsWith:observing:_:sourceLocation:performing:)`` or
79+
/// ``require(exitsWith:observing:_:sourceLocation:performing:)``.
8080
///
8181
/// If the exit test could not be started or if you did not request standard
8282
/// error content, the value of this property is the empty array.

0 commit comments

Comments
 (0)