End-to-End Testing
In this chapter, we will look at how to create an End-to-End (E2E) test suite for a Vue.js application with Cypress. In order to write robust tests, we’ll look at common pitfalls and best practices, such as intercepting HTTP requests and waiting for elements to appear without timeouts.
As we proceed, you will gain an understanding of E2E testing and its use cases. You will see how Cypress can be configured to test a Vue.js application and also interact with and inspect a User Interface (UI) using it. Throughout the chapter, you will gain familiarity with the pitfalls of arbitrary timeouts and how to avoid them with Cypress’ waiting functionality.
Toward the end of the chapter, you will also learn when, why, and how to intercept HTTP requests with Cypress.
In this chapter, we will cover the following topics:
- Understanding E2E testing and its use cases
- Configuring Cypress for a Vue.js application
- Using Cypress to interact with...