Skip to content

Commit a3e0dea

Browse files
committed
test: scope desktop shell checks by platform
Verify the macOS and Windows release jobs independently so one duplicated shell declaration cannot mask a missing platform configuration.
1 parent 019e4d0 commit a3e0dea

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

scripts/release/release-workflows.test.mjs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,10 @@ const read = (path) => readFileSync(resolve(root, path), 'utf8');
88

99
void test('desktop releases configure both platforms with Bash', () => {
1010
const workflow = read('.github/workflows/desktop-release.yml');
11-
const configuredWithBash = workflow.match(/^ - name: Configure desktop release\n shell: bash$/gmu);
12-
assert.equal(configuredWithBash?.length ?? 0, 2);
11+
const configuredWithBash = /^ - name: Configure desktop release\n shell: bash$/mu;
12+
const windowsStart = workflow.indexOf('\n windows:');
13+
assert.match(workflow.slice(workflow.indexOf('\n mac:'), windowsStart), configuredWithBash);
14+
assert.match(workflow.slice(windowsStart, workflow.indexOf('\n publish:', windowsStart)), configuredWithBash);
1315
});
1416

1517
void test('release workflow uses full push-boundary lane signals and isolated jobs', () => {

0 commit comments

Comments
 (0)