apple / apple/swift-argument-parser

Provide integrations with Swift Testing exit tests

Open
#759 5 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Swift
Stars
3.8k
Forks
411
Avg merge
7d 13h
Merged PRs (30d)
17

Description

(Will add more detail when I return from leave.)

Swift Testing is introducing a new "exit tests" feature in Swift 6.2. Would be great if we could find a way to integrate it with the argument parser, e.g. something like:

```swift
await #expect(arguments: ["--foo", "bar", ...], exitWith: .success)
```

Contributor guide

Open the contributing guide

Research direction

Start by reviewing Swift 6.2 Swift Testing exit tests and the argument parser's existing testing integration points. Define how an argument invocation should be checked against an expected exit result, using the proposed await #expect(arguments:exitWith:) example as the target. Done means the integration behavior and API are specified and covered by tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
swift
Domain
cli, testing
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.