fix: rename Windows ZIPs and fix macOS manual update checks (#81)

This commit is contained in:
sudacode authored and GitHub committed 2026-05-24 23:47:02 -07:00
1 parent 10463e7348
commit 17d97f0b7e
11 files changed
+133 -8

No files matched your search

@@ -2,7 +2,7 @@ import assert from 'node:assert/strict';
import test from 'node:test';
import { shouldFetchReleaseMetadataForPlatform } from './release-metadata-policy';
test('macOS release metadata fetch is skipped only when native updater is unsupported', () => {
test('macOS automatic release metadata fetch is skipped when native updater is unsupported', () => {
assert.equal(
shouldFetchReleaseMetadataForPlatform('darwin', {
available: false,
@@ -28,6 +28,33 @@ test('macOS release metadata fetch is skipped only when native updater is unsupp
);
});
test('macOS manual checks fetch release metadata when native updater is unsupported', () => {
const unsupportedUpdate = {
available: false,
version: '0.15.0-beta.4',
canUpdate: false,
};
assert.equal(
shouldFetchReleaseMetadataForPlatform('darwin', unsupportedUpdate, {
source: 'manual',
}),
true,
);
assert.equal(
shouldFetchReleaseMetadataForPlatform('darwin', unsupportedUpdate, {
source: 'launcher',
}),
true,
);
assert.equal(
shouldFetchReleaseMetadataForPlatform('darwin', unsupportedUpdate, {
source: 'automatic',
}),
false,
);
});
test('non-macOS release metadata fetch is not gated by native updater support', () => {
assert.equal(
shouldFetchReleaseMetadataForPlatform('linux', {