chore: clean up docker-compose files and enhance SQL migration for skills
Deploy Development / deploy (push) Successful in 36s
Test Suite / lint-backend (push) Successful in 1s
Test Suite / build-frontend (push) Successful in 6s
Test Suite / playwright-tests (push) Failing after 40s

- Removed version specification from docker-compose.dev-env.yml and docker-compose.yml for consistency.
- Added a unique constraint to the skills table in the SQL migration to prevent duplicate entries, ensuring data integrity during imports.
- Updated test cases in dev-smoke-test.spec.js to improve locator strategies and enhance viewport handling for mobile navigation.
This commit is contained in:
Lars committed 2026-04-29 13:41:17 +02:00
1 parent fe86d763ad
commit 07b1cd8209
4 files changed
+30 -16

No files matched your search

+18 -12
View File
@@ -43,8 +43,10 @@ test('2. Dashboard lädt ohne Fehler', async ({ page }) => {
// Warte bis Spinner verschwunden
await expect(page.locator('.spinner')).toHaveCount(0, { timeout: 10000 });
// Prüfe ob Dashboard-Inhalt da ist
await expect(page.locator('text=Willkommen')).toBeVisible({ timeout: 5000 });
// Zwei verschiedene "Willkommen"-Texte im Dashboard → kein ambiguity locator('text=Willkommen')
await expect(
page.getByRole('heading', { name: /Willkommen bei Shinkan/i }),
).toBeVisible({ timeout: 5000 });
await page.screenshot({ path: 'screenshots/02-dashboard.png' });
console.log('✓ Dashboard OK');
@@ -53,8 +55,11 @@ test('2. Dashboard lädt ohne Fehler', async ({ page }) => {
test('3. Navigation zu Übungen', async ({ page }) => {
await login(page);
// Bottom-Nav: Übungen klicken
await page.click('text=Übungen');
// Bei Viewport ≥1024px ist .bottom-nav versteckt — Mobile garantieren wie in playwright.config.js
await page.setViewportSize({ width: 390, height: 844 });
// Desktop-Sidebar enthält ebenfalls Übungen – nur Mobile-Bottom-Nav klicken (sichtbarer Link)
await page.locator('.bottom-nav a[href="/exercises"]').click();
await page.waitForLoadState('networkidle');
// Prüfe ob Übungen-Seite geladen
@@ -66,9 +71,9 @@ test('3. Navigation zu Übungen', async ({ page }) => {
test('4. Navigation zu Vereine', async ({ page }) => {
await login(page);
await page.setViewportSize({ width: 390, height: 844 });
// Bottom-Nav: Vereine klicken
await page.click('text=Vereine');
await page.locator('.bottom-nav a[href="/clubs"]').click();
await page.waitForLoadState('networkidle');
// Prüfe ob Vereine-Seite geladen
@@ -109,16 +114,17 @@ test('6. Bottom-Nav sichtbar (Mobile)', async ({ page }) => {
test('7. Session-Persistenz nach Reload', async ({ page }) => {
await login(page);
// Warte auf Dashboard
await expect(page.locator('.spinner')).toHaveCount(0, { timeout: 10000 });
// Reload
await page.reload();
await page.reload({ waitUntil: 'domcontentloaded' });
await page.waitForLoadState('networkidle');
// Sollte NICHT zur Login-Seite redirecten
const loginButton = page.locator('button:has-text("Login")');
await expect(loginButton).toHaveCount(0, { timeout: 5000 });
// Auth lädt erst nach Spinner – nicht auf /login stranden (stabiler als Button „Login“-Tab auf Login-Screen)
await expect(page.locator('.spinner')).toHaveCount(0, { timeout: 20000 });
await expect(page).not.toHaveURL('**/login', { timeout: 20000 });
await expect(page.locator('h1').filter({ hasText: /^Dashboard$/ })).toBeVisible({
timeout: 10000,
});
await page.screenshot({ path: 'screenshots/07-nach-reload.png' });
console.log('✓ Session bleibt nach Reload erhalten');