Hive Hive
Sign in

fix(cli): apply test quarantine to –without-building and shard runs

GitHub issue · Closed

Metadata
Source
tuist/tuist #10864
Updated
Jun 24, 2026
Domains
CLI
Details

Describe here the purpose of your PR.

Quarantined tests marked as skipped in the dashboard were still running when CI used the bundle-bypass or shard code paths.

The fetch + skip-target merge in TestService.run lived after the early-returns into runShard and runTestWithoutBuildingFromBundle. Both helpers received the original skipTestTargets, never queried the server, and even passed quarantinedTests: [] into the local summary. So:

  • tuist test --without-building -testProductsPath <bundle> (typical Bitrise build-VM → test-VM split) skipped the quarantine fetch entirely.
  • tuist test --without-building --shard-index N did the same.
  • No Found N quarantined test(s) log fired on either path, so the regression was silent.

This PR:

  • Extracts fetchQuarantinedTests(skipQuarantine:config:) and calls it once near the top of run().
  • Merges skipTestTargets + skippedQuarantinedTests before branching, so every code path sends the same -skip-testing set to xcodebuild.
  • Threads the muted list through runShard and runTestWithoutBuildingFromBundle so their uploaded summaries mark quarantined results consistently with the main path.
  • Adds regression tests for both bypass paths and for --skip-quarantine on the bundle path.

How to test locally

  1. On a project with fullHandle set, mark a failing test as skipped in the dashboard.
  2. Build with tuist test --without-building --build-only (or your equivalent build-VM step) and ship the .xctestproducts to a separate runner.
  3. On the runner: tuist test --without-building -testProductsPath <bundle> … — the quarantined test should now be passed to xcodebuild as -skip-testing and not executed. The CLI logs Found 1 quarantined test(s): 0 muted, 1 skipped.
  4. Repeat with --shard-index N to confirm the shard path applies it too.
Comments