Iteration H2: Testing Our JavaScript Functionality
Now that we have application-level functionality in JavaScript code, we are going to need to have tests in place to ensure that the function not only works as intended but continues to work as we make changes to the application.
Testing this functionality involves a lot of steps: visiting the store, selecting an item, adding that item to the card, clicking checkout, filling in a few fields, and selecting a payment type. And from a testing perspective, we are going to need both a Rails server and a browser.
To accomplish this, Rails makes use of a version of the popular Google Chrome web browser named ChromeDriver,[74] which has been augmented to include programming interfaces to enable automation, ...
Get Agile Web Development with Rails 5.1 now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.