This document captures the practical coding habits used in this repository today.
Core Guidelines
-
Use the Page Object Model for UI interactions.
-
Prefer Playwright locators such as
getByRole()andgetByLabel(). -
Avoid brittle CSS or XPath selectors unless needed for a specific UI.
-
Use
asyncandawaitconsistently for browser interactions. -
Avoid fixed timeouts; prefer assertion-driven or state-based waits.
-
Keep test data separate from test logic where that improves reuse and readability.
-
Reuse existing helpers, page objects, and shared data before creating new patterns.
-
Keep tests easy to read, with meaningful assertions and focused workflows.
Repository-Specific Notes
-
The active page object directory is
pageObjects/. -
Navigation helpers exist in
utils/gotoHelper.ts. -
Shared navigation metadata exists in
data/navigationSections.ts. -
pnpmis the intended package manager for this repo.
This guide will continue to evolve as the project grows.