From the course: Learning Playwright

Unlock this course with a free trial

Join today to access over 24,200 courses taught by industry experts.

Challenge: Create three automated tests

Challenge: Create three automated tests

From the course: Learning Playwright

Challenge: Create three automated tests

- [Instructor] Now that we've covered a lot of the basics with Playwright test automation, now it's your turn to write some code. For this challenge, I want you to create an automated test that adds an item to the shopping cart, goes through the checkout process, and when paying, selects buy now, pay later. I also want you to create a visual test to the checkout flow to validate the final payment screen. And lastly, create an API test against the endpoint slash products slash unique ID, ensuring the correct product details are returned in the API response. I'll leave you with a few hints to help you get started. Back in video six, where we walked through setting up the storage state, this includes an authenticated user for one of the customers. Using this will save you a few steps in your test. Also, for the API test, the product IDs get automatically updated every two hours due to the database resetting. This is a practice test site. You'll need to find a way to reliably get the…

Contents