chore: merge main into branch; resolve ChronikRow conflict
Some checks failed
CI / Unit & Component Tests (pull_request) Failing after 4m21s
CI / OCR Service Tests (pull_request) Successful in 42s
CI / Backend Unit Tests (pull_request) Failing after 3m36s
CI / Unit & Component Tests (push) Failing after 3m46s
CI / OCR Service Tests (push) Successful in 31s
CI / Backend Unit Tests (push) Failing after 3m17s

TODO/SECURITY placeholders from main are superseded by the #454 implementation.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit was merged in pull request #475.
This commit is contained in:
Marcel
2026-05-07 20:05:12 +02:00
74 changed files with 317 additions and 4176 deletions

View File

@@ -1,6 +1,6 @@
import { describe, it, expect, vi, afterEach } from 'vitest';
import { cleanup, render } from 'vitest-browser-svelte';
import { page, userEvent } from 'vitest/browser';
import { page } from 'vitest/browser';
import ChronikErrorCard from './ChronikErrorCard.svelte';
@@ -10,7 +10,7 @@ describe('ChronikErrorCard', () => {
it('renders the default error message', async () => {
render(ChronikErrorCard, { onRetry: vi.fn() });
await expect
.element(page.getByText('Die Chronik konnte nicht geladen werden.'))
.element(page.getByText('Die Aktivitäten konnten nicht geladen werden.'))
.toBeInTheDocument();
});
@@ -27,7 +27,8 @@ describe('ChronikErrorCard', () => {
it('calls onRetry when the retry button is clicked', async () => {
const onRetry = vi.fn();
render(ChronikErrorCard, { onRetry });
await userEvent.click(page.getByText('Erneut versuchen'));
const btn = (await page.getByText('Erneut versuchen').element()) as HTMLElement;
btn.dispatchEvent(new MouseEvent('click', { bubbles: true, cancelable: true }));
expect(onRetry).toHaveBeenCalledTimes(1);
});