1
0
forked from boos/BoosAPI

test: relax token selection count assertion

This commit is contained in:
Cita
2026-03-23 14:51:57 +08:00
parent 4686c558aa
commit 426d9a538d
@@ -211,8 +211,7 @@ describe('Tokens edit modal and row selection', () => {
}); });
await flushMicrotasks(); await flushMicrotasks();
expect(JSON.stringify(root.toJSON())).toContain('已选 '); expect(collectText(root.root)).toContain('已选 1 项');
expect(JSON.stringify(root.toJSON())).toContain('"1"');
const copyButton = root.root const copyButton = root.root
.findAll((node) => node.type === 'button') .findAll((node) => node.type === 'button')
@@ -224,8 +223,7 @@ describe('Tokens edit modal and row selection', () => {
}); });
await flushMicrotasks(); await flushMicrotasks();
expect(JSON.stringify(root.toJSON())).toContain('已选 '); expect(collectText(root.root)).toContain('已选 1 项');
expect(JSON.stringify(root.toJSON())).toContain('"1"');
} finally { } finally {
root?.unmount(); root?.unmount();
} }