test(staples): add empty categories edge case to StaplesManager

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-04-03 09:23:48 +02:00
parent 7979076f5e
commit 7b497be1c1

View File

@@ -99,4 +99,9 @@ describe('StaplesManager', () => {
const grid = screen.getByTestId('category-grid'); const grid = screen.getByTestId('category-grid');
expect(grid.className).toContain('md:grid-cols-3'); expect(grid.className).toContain('md:grid-cols-3');
}); });
it('renders without crashing when categories is empty', () => {
render(StaplesManager, { props: { categories: [], context: 'onboarding' } });
expect(screen.queryByRole('button')).not.toBeInTheDocument();
});
}); });