const { test } = require('@playwright/test'); const USER = process.env.FD_USER || 'e2e@flowdeck.local'; const PASS = process.env.FD_PASS || 'e2e-secret-123'; async function uiLogin(page) { await page.goto('/auth/login?provider=local'); await page.fill('#email', USER); await page.fill('#password', PASS); await page.click('.btn-primary'); await page.waitForTimeout(1500); } test('explore: home après login UI', async ({ page }) => { await uiLogin(page); console.log('URL après login:', page.url()); console.log('TITLE:', await page.title()); // buttons with "New"/create const newBtns = await page.evaluate(() => [...document.querySelectorAll('button, a, [role=button]')] .map(b => ({ t: (b.innerText||'').trim().slice(0, 25), cls: (b.className||'').toString().slice(0,30) })) .filter(x => /new|creat|add|page|meeting|database/i.test(x.t)) ); console.log('NEW-ISH BUTTONS:', JSON.stringify(newBtns, null, 1)); await page.screenshot({ path: 'shots/home.png', fullPage: false }); });