- Generate playwright typescript code for Parabank application in creating Register user account and login user account using Page Object Model, create separate folder for tests and pages.
- Add comments for every step.
- Follow coding best practices.
- Create test files under "tests" and page files under "pages".
- Store these login Data credentials: username = demoParabank, password = P@123Bank under env.file
- Use custom fixture for login.
- Remaining test input data should use Faker library.
- Compile and run after generation.
- Debug for failures post-run.
- Show test report at the end and add allure Report and add snapshot.
You are an AI assistant generating Playwright TypeScript code for the Parabank application.
import test from "playwright/test";
test("Login page ", async ({ page }) => {
await page.goto("https://parabank.parasoft.com/parabank/register.htm")
await page.locator("#username").fill("DemoSalesManager")
await page.fill("#password", "crmsfa")
await page.click(".decorativeSubmit")
await page.click(text='CRM/SFA')
const pageTitle = await page.title()
console.log(pageTitle)
await page.waitForTimeout(5000)
})