kin: auto-commit after pipeline

This commit is contained in:
Gros Frumos 2026-03-17 16:50:44 +02:00
parent 0731aad028
commit 79a0e524a7
3 changed files with 107 additions and 0 deletions

View file

@ -256,6 +256,23 @@ describe('KIN-099: onUnmounted очищает setTimeout таймеры watchdog
await flushPromises()
// Pass = no errors thrown after unmount
})
it('KIN-OBS-016: vi.getTimerCount() === 0 после unmount — все таймеры очищены', async () => {
vi.mocked(api.notifications).mockResolvedValue([
makeNotification('KIN-016', 'Process died unexpectedly (PID 99999)'),
])
const wrapper = mount(EscalationBanner)
await flushPromises()
// Toast с активным timerId должен быть виден
expect(wrapper.find('.border-red-700').exists()).toBe(true)
// После unmount — оба таймера (setInterval pollTimer + setTimeout toast) очищены
wrapper.unmount()
expect(vi.getTimerCount()).toBe(0)
})
})
// ─────────────────────────────────────────────────────────────