Fix e2e cleanup#7936
Merged
Merged
Conversation
Assisted-By: devx/6d93e11e-762b-48c5-9bcf-265de5035498
nelsonwittwer
approved these changes
Jun 26, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Why
The e2e tests create temporary Shopify apps in the Dev Dashboard. Each app name includes the GitHub Actions run token, for example
E2E-scaf-rcyjrwc3a1-mqu8cgqh, so cleanup can find everything created by one run.A previous run left apps behind even though the cleanup step ran. The per-test delete flow failed on a Dev Dashboard error page, then the fallback cleanup opened the apps list and saw
0app cards. Because the script treated that as a real empty result, it exited successfully instead of retrying or failing.What
This makes the fallback cleanup more reliable:
search_term=<run token>, so the page only returns apps from the current e2e run instead of scanning every app in the org.No apps matched your search.) as a valid zero-result cleanup.Testing
pnpm --filter e2e exec tsx scripts/cleanup-apps.ts --list --pattern rcyjrwc3a1pnpm --filter e2e exec tsx scripts/cleanup-apps.ts --list --pattern rcyjrwc3a1sspnpm --filter e2e type-checkgit diff --check