E2E Testing (End-to-End Testing)
A testing methodology that validates the entire application workflow from start to finish, simulating real user scenarios including UI, APIs, databases, and external integrations.
Definition
E2E tests verify that all components work together correctly from a user's perspective. They interact with the application through the UI (clicking buttons, filling forms) and verify outcomes. Popular tools include Playwright (Microsoft), Cypress (JavaScript), and Selenium. E2E tests are slower and more brittle than unit tests but catch integration issues that unit tests miss. They sit at the top of the testing pyramid.
Why It Matters
E2E tests catch bugs that slip through unit and integration tests — issues in user workflows, UI rendering problems, and integration failures. According to research, E2E tests find 2x more critical bugs than unit tests. However, they're expensive to maintain, so teams typically focus on critical user paths.
Example
An E2E test for checkout: opens the browser, logs in as a user, adds items to cart, proceeds to checkout, enters payment info, submits order, and verifies the confirmation page and email.