13 lines
561 B
JavaScript
13 lines
561 B
JavaScript
|
|
import { describe, it, expect } from 'vitest';
|
||
|
|
import { resetSession } from './standby-session-reset.mjs';
|
||
|
|
|
||
|
|
describe('resetSession — сброс штатного на старте сессии', () => {
|
||
|
|
it('снимает standby-mode и standby-pending для сессии', () => {
|
||
|
|
const calls = [];
|
||
|
|
const remove = (name, sess) => { calls.push([name, sess]); return true; };
|
||
|
|
resetSession('sess-X', remove);
|
||
|
|
expect(calls).toContainEqual(['standby-mode', 'sess-X']);
|
||
|
|
expect(calls).toContainEqual(['standby-pending', 'sess-X']);
|
||
|
|
});
|
||
|
|
});
|