Repository navigation
Features
-
Write Cucumber JSON reports and verbose output with Swift Testing (#420, #433 by @ianhlavats)
-
Run feature hooks and attachments with Swift Testing (#421, #435 by @ianhlavats)
-
Bring the Swift Testing runner's step and hook options in line with CucumberSwift (#422, #434 by @ianhlavats)
-
Run Swift Testing scenarios in parallel (#432, #436 by @ianhlavats)
-
Add expectations, readable test names and a test per step to the Swift Testing runner (#441, #444 by @ianhlavats)
-
Add macro forms of the hooks (#443, #445 by @ianhlavats)
-
Suggest missing step definitions as macros (#453, #456 by @ianhlavats)
-
Make the Swift Testing JSON report match the XCTest report's uri and file name (#463, #466 by @ianhlavats)
Migration:
In Swift Testing mode,
Feature.uri, as hooks,shouldRunWith(scenario:tags:)and custom observers see it, is now thefile://URL of the feature file's copy in the test bundle, as with XCTest, not a plain source path. Code that builds a URL withURL(fileURLWithPath: feature.uri)should useURL(string: feature.uri)instead. Failures in Xcode still point at the editable feature file.CucumberTestResultsFor<target>.jsonis now written in Swift Testing mode too, and in both modes it is replaced on every run instead of keeping the first run's report. -
Let a step skip the rest of its scenario in Swift Testing, as XCTSkip does in XCTest (#470, #471 by @ianhlavats)
Bugs
-
Fix wait(for:timeout:), which never fails a step (#442, #449 by @ianhlavats)
Migration:
wait(for:timeout:)now fails the step, with XCTest and with Swift Testing, when the timeout passes before every expectation is fulfilled, or when an inverted expectation is fulfilled, as XCTest'swait(for:timeout:)fails a test. Until now such a wait passed, so a scenario whose wait times out will now fail. To fix it, make sure the expectation is fulfilled within the timeout, or raise the timeout. In anasyncstep, writeawait wait(for:timeout:): a synchronous wait there holds the main actor, so work on the main actor or the main queue can't fulfill the expectation. -
A Rule's Scenario Outlines never run, and its tags are dropped (#468, #469 by @ianhlavats)
Migration:
Scenario Outlines inside a
Ruleused to be skipped silently. They now run, with the feature's and the rule's Background steps, so a suite can see new passing or failing examples. Tags above aRuleused to reach only the rule's first scenario; they now apply to every scenario and example in the rule, after the feature's tags and before each scenario's own. A tag filter (CUCUMBER_TAGSorshouldRunWith(scenario:tags:)) that selects a rule's tag now selects all of the rule's scenarios. Check filters that relied on the old behaviour.
Tasks
-
Parallel tests (iOS, UI, Xcode 16) often fail because the UI test can't start or stop the fixture app (#375, #431 by @ianhlavats)
-
Document how to use the step definition macros (#419, #430 by @ianhlavats)
-
Separate what the Swift Testing runner leaves out by design from what it lacks (#423, #455 by @ianhlavats)
-
Deprecate ExecuteFirstStep in favour of shared helper functions (#446, #447 by @ianhlavats)
Migration:
ExecuteFirstStepis deprecated in both runners and will be removed in the next major version. It still works, with a deprecation warning. Move the shared logic into a helper function that both step definitions call (see "Running another step" in Matching Steps). -
Let mise run test-fixtures run only the fixtures named in FIXTURES (#448, #450 by @ianhlavats)
-
Run SwiftLint in CI so lint errors can't reach main (#451, #454 by @ianhlavats)
-
Show the step and hook macros in every documentation example (#452, #457 by @ianhlavats)
Other changes
- chore(actions): bump the codeql-action group with 2 updates (#460 by dependabot[bot])
- chore(actions): bump actions/create-github-app-token from 3.2.0 to 3.3.0 (#461 by dependabot[bot])
Full list of changes: 6.6.0...6.7.0