Files
wehub-resource-sync c48612c494
CI / E2E Tests (push) Has been cancelled
CI / Lint, Typecheck & Unit Tests (push) Has been cancelled
Docs Build / Build docs site (push) Has been cancelled
Publish @openmaic packages / Build, validate & publish (push) Has been cancelled
chore: import upstream snapshot with attribution
2026-07-13 13:03:23 +08:00

13 lines
475 B
TypeScript

import { describe, expect, it } from 'vitest';
import { getHiddenCells } from '@/components/slide-renderer/components/element/TableElement/tableUtils';
describe('tableUtils', () => {
it('tolerates malformed rows and null cells when computing hidden cells', () => {
const data = [[{ id: 'a', text: 'x', colspan: 2 }, null], null, 5] as never;
expect(() => getHiddenCells(data)).not.toThrow();
expect(getHiddenCells(data)).toEqual(new Set(['0_1']));
});
});