Skip to content

[eas-cli] Respect --no-auto-testflight-setup when submitting without ascAppId - #4426

Open
tahakocal wants to merge 2 commits into
expo:mainfrom
tahakocal:fix/submit-no-auto-testflight-setup
Open

tahakocal wants to merge 2 commits into
expo:mainfrom
tahakocal:fix/submit-no-auto-testflight-setup

Conversation

@tahakocal

Copy link
Copy Markdown

Why

Fixes #4397

eas submit -p ios --no-auto-testflight-setup still creates the internal Team (Expo) TestFlight group and invites the team's admins when the submit profile has no ascAppId.

#4136 replaced the EAS_NO_AUTO_TESTFLIGHT_SETUP check with the --auto-testflight-setup flag, but only honored the flag on the existing-app path (ensureTestFlightSetupForExistingAppAsync). When the App Store Connect app is resolved by bundle identifier (ensureAppStoreConnectAppExistsAsynccreateAppStoreConnectAppAsync), the group setup still runs unconditionally.

How

Run the group setup in createAppStoreConnectAppAsync only when ctx.autoTestFlightSetup is true, matching ensureTestFlightSetupForExistingAppAsync. Nothing else changes when the flag is omitted or passed explicitly.

eas build --auto-submit and submit:internal don't pass autoTestFlightSetup to the submission context, so they still always set up the group. eas build has no equivalent flag, so I left that out of this PR.

Test Plan

  • Added AppProduce-test.ts, which covers group setup with autoTestFlightSetup enabled and disabled. The disabled case fails without this change.
  • src/submit tests pass (10 suites, 66 tests), and tsc, oxlint and oxfmt --check are clean.
  • Ran an end-to-end check through the real flag parsing (Submit.flags with oclif), createSubmissionContextAsync, IosSubmitCommand.runAsync() and submitAsync(), with only the Apple and network calls mocked. The profile had no ascAppId:
CLI arguments Before After
--platform ios group set up group set up
--platform ios --auto-testflight-setup group set up group set up
--platform ios --no-auto-testflight-setup group set up skipped

…ascAppId

The flag was only checked when the submit profile has an ascAppId. When the
App Store Connect app is resolved by bundle identifier instead, `eas submit`
still created the internal TestFlight group and invited the team's admins.

Fixes expo#4397
@github-actions

Copy link
Copy Markdown

Subscribed to pull request

File Patterns Mentions
packages/eas-cli/** @douglowder

Generated by CodeMention

Warning: The preamble and epilogue options in commentConfiguration are deprecated. Use template instead.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant