fix(i18n): unify shared view states

This commit is contained in:
cesnimda
2026-08-29 23:37:07 +02:00
parent 360b992b37
commit 10ce0f2086
9 changed files with 98 additions and 38 deletions
@@ -46,6 +46,7 @@ function renderBoard() {
beforeEach(() => {
jest.clearAllMocks();
window.localStorage.clear();
});
test('the board collapses ten stages into the three agreed groups', async () => {
@@ -108,6 +109,16 @@ test('loading and retryable error states replace the board', async () => {
expect(await screen.findByRole('group', { name: 'Not Applied column' })).toBeInTheDocument();
});
test('loading and retry controls follow the selected Bokmål locale', async () => {
window.localStorage.setItem('uiLanguage', 'nb-NO');
mockedApi.get.mockRejectedValueOnce(new Error('offline'));
renderBoard();
expect(await screen.findByText('Kunne ikke laste kanban-tavlen')).toBeInTheDocument();
expect(screen.getByRole('button', { name: 'Prøv igjen' })).toBeInTheDocument();
});
test('dropping onto a group applies that group entry stage', async () => {
mockedApi.get.mockResolvedValue({ data: [job(7, 'Saved Role', 'Saved')] } as any);