mirror of
https://github.com/getpaseo/paseo.git
synced 2026-10-26 03:03:04 +00:00
fix(release): distribute stable iOS builds to TestFlight testers (#7189)
Replace the upload-only submission with the existing TestFlight distribution job shape so external testers receive stable releases. Keep App Store review targeting the same version and build without a second binary upload.
This commit is contained in:
@@ -37,7 +37,7 @@ function jobBlocks(source) {
|
||||
let currentJob;
|
||||
|
||||
for (const line of source.split("\n")) {
|
||||
const jobMatch = /^ ([a-z0-9-]+):\s*$/.exec(line);
|
||||
const jobMatch = /^ ([a-z0-9_-]+):\s*$/.exec(line);
|
||||
if (jobMatch) {
|
||||
currentJob = jobMatch[1];
|
||||
jobs.set(currentJob, []);
|
||||
@@ -303,3 +303,31 @@ test("desktop packaging smokes main pushes and only the pull requests that touch
|
||||
assert.match(source, new RegExp(`${action}@[0-9a-f]{40} # v\\d+\\.\\d+\\.\\d+`));
|
||||
}
|
||||
});
|
||||
|
||||
test("stable iOS releases upload once and distribute to external testers before App Store review", () => {
|
||||
const source = readFileSync(
|
||||
new URL("packages/app/.eas/workflows/release-mobile.yml", repoRoot),
|
||||
"utf8",
|
||||
);
|
||||
const jobs = jobBlocks(source);
|
||||
const uploads = [...jobs.entries()].filter(
|
||||
([, lines]) =>
|
||||
lines.some((line) => /^ type: (submit|testflight)$/.test(line)) &&
|
||||
lines.some((line) => line.includes("needs.build_ios.outputs.build_id")),
|
||||
);
|
||||
assert.equal(uploads.length, 1, "the iOS binary must be uploaded exactly once");
|
||||
const [distributionId, distributionLines] = uploads[0];
|
||||
const distribution = distributionLines.join("\n");
|
||||
assert.match(distribution, /^ type: testflight$/m);
|
||||
assert.match(distribution, /external_groups:\s*\n\s+- Paseo Beta/);
|
||||
assert.match(distribution, /^ submit_beta_review: true$/m);
|
||||
|
||||
const review = jobs.get("submit_ios_for_review").join("\n");
|
||||
assert.match(review, new RegExp(`needs: \\[build_ios, ${distributionId}\\]`));
|
||||
assert.match(review, /APP_VERSION="\$\{\{ needs\.build_ios\.outputs\.app_version \}\}"/);
|
||||
assert.match(
|
||||
review,
|
||||
/APP_BUILD_VERSION="\$\{\{ needs\.build_ios\.outputs\.app_build_version \}\}"/,
|
||||
);
|
||||
assert.match(review, /bundle exec fastlane ios submit_review/);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user