This project uses Playwright to run end-to-end tests that simulate key user flows on the Robinhood website. Its primary goal is to collect front-end performance metrics, enabling the visualization of trends and the identification of performance regressions over time.
To proactively monitor the front-end performance of critical user flows on Robinhood, ensuring a fast and responsive user experience. This is achieved by:
- Simulating real user interactions with Playwright.
- Collecting detailed performance data from the browser.
- Storing and analyzing these metrics to detect slowdowns.
- Playwright Test Scripts: Automate user flows and gather raw performance data using browser APIs.
- Data Ingestion & Storage: A mechanism to save collected metrics (e.g., JSON files, a database) for historical analysis.
- Reporting & Visualization: A dashboard to display performance trends, compare results, and highlight regressions.
The following user journeys are simulated to cover critical application functionality:
- Login & Dashboard Load: Authenticates the user and measures the time to a fully loaded and interactive dashboard.
- Stock Search & Detail View: Searches for a stock (e.g., AAPL) and measures the time to render its detailed information and charts.
- Simulated Order Placement: Steps through the "buy" order flow up to the final confirmation screen.
- Account Navigation: Navigates to key account sections like settings or statements.
Before running the tests, you must provide your login credentials.
- Create a file named
test-credentials.json
in the root of the project. - Add your credentials in the following format:
{ "email": "[email protected]", "password": "your-password" }
Note: This file is included in
.gitignore
and should never be committed to version control.
Installs all the dependencies required for the project.
Runs all the test cases using Playwright. This will first trigger the global setup for authentication and then execute the performance monitoring tests.
Checks the code for any linting errors using ESLint.
Automatically fixes the linting errors in the code.