diff --git a/scripts/release.mjs b/scripts/release.mjs index 913cbc75..f01a633a 100644 --- a/scripts/release.mjs +++ b/scripts/release.mjs @@ -1449,6 +1449,7 @@ const releaseMain = async (options) => { mobileRebuild: mobilePlan.rebuild, changesEn: options.changesEn, changesZh: options.changesZh, + localizedChanges: options.localizedChanges, }); run("git", ["add", ...versionPaths]); run("git", ["diff", "--cached", "--check"]); diff --git a/scripts/release.test.mjs b/scripts/release.test.mjs index 6ee42788..c6d89604 100644 --- a/scripts/release.test.mjs +++ b/scripts/release.test.mjs @@ -417,6 +417,19 @@ describe("release automation", () => { }); }); + test("persists localized in-app release changes when preparing versions", () => { + const releaseSource = readFileSync(new URL("./release.mjs", import.meta.url), "utf8"); + const updateCall = releaseSource.indexOf("const versionPaths = updateReleaseVersions({"); + const localizedChanges = releaseSource.indexOf( + "localizedChanges: options.localizedChanges", + updateCall, + ); + const updateCallEnd = releaseSource.indexOf("});", updateCall); + expect(updateCall).toBeGreaterThanOrEqual(0); + expect(localizedChanges).toBeGreaterThan(updateCall); + expect(localizedChanges).toBeLessThan(updateCallEnd); + }); + test("builds a bilingual umbrella Issue", () => { const body = buildIssueBody({ changesEn: ["Parallel checks."],