The main activities of an e2e test for any web page are to get the DOM elements of that page, interact with them, assign an action to them, and share information with them; then, the user can get the current state of the website. To enable us to perform all these actions, Protractor provides a wide array of APIs (some are from the web driver). In this chapter, we will look at some commonly used APIs.
In the previous chapter, we saw how Protractor works with an Angular project, where we had to interact with UI elements. For that, we used a few Protractor APIs, such as
getText. However, we didn't see or understand the workings of these APIs in depth. To understand the workings of APIs in Protractor ...