Checkout: minimize registration data
Some checks failed
linter / quality (push) Has been cancelled
tests / ci (push) Has been cancelled
tests / ui (push) Has been cancelled

This commit is contained in:
Codex Agent
2026-01-06 09:23:01 +01:00
parent 29c3c42134
commit 33af04db1b
9 changed files with 105 additions and 157 deletions

View File

@@ -171,12 +171,20 @@ async function completeRegistrationOrLogin(page: Page, credentials: { email: str
await page.fill('input[name="first_name"]', 'Play');
await page.fill('input[name="last_name"]', 'Wright');
await page.fill('input[name="email"]', credentials.email);
await page.fill('input[name="address"]', 'Teststrasse 1, 12345 Berlin');
await page.fill('input[name="phone"]', '+49123456789');
const addressInput = page.locator('input[name="address"]');
if (await addressInput.isVisible()) {
await addressInput.fill('Teststrasse 1, 12345 Berlin');
}
const username = credentials.email.split('@')[0]?.replace(/[^a-z0-9]+/gi, '-') ?? `playwright-${Date.now()}`;
await page.fill('input[name="username"]', username);
const phoneInput = page.locator('input[name="phone"]');
if (await phoneInput.isVisible()) {
await phoneInput.fill('+49123456789');
}
const usernameInput = page.locator('input[name="username"]');
if (await usernameInput.isVisible()) {
await usernameInput.fill(credentials.email);
}
await page.fill('input[name="password"]', credentials.password);
await page.fill('input[name="password_confirmation"]', credentials.password);