feat(updater): support updates after verified SeaweedFS migration

This commit is contained in:
2026-09-28 15:47:06 +02:00
parent 790f20b499
commit 2b947c5e8f
20 changed files with 1074 additions and 67 deletions

View File

@@ -82,6 +82,19 @@ test('recovery, up-to-date, unmanaged compose and other active jobs prevent appl
}
})
test('a completed storage migration stays blocked until the host handover is complete', async t => {
let state = { ...overview(check, { status: 'failed', recoveryRequired: true }),
storage: { provider: 'seaweedfs', migrationPending: true } }
const f = await setup(t, async path => path.endsWith('/status') ? state : state.request)
assert.equal(f.ui.overview.value.storage.migrationPending, true)
assert.equal(f.ui.canApply.value, false)
state = { ...overview({ ...check, plan: { ...check.plan, storageProvider: 'seaweedfs', storageImageRetained: true } }),
storage: { provider: 'seaweedfs', migrationPending: false } }
await f.ui.refresh()
assert.equal(f.ui.canApply.value, true)
assert.equal(f.ui.job.value.plan.storageProvider, 'seaweedfs')
})
test('an older polling response cannot erase a new submission whose response was lost', async t => {
let hold = false, release
const f = await setup(t, async (path, options) => {