Hands-On Web UI Testing

120-minute Tutorial - Saturday, July 27 at 3:00pm in Suzanne Scharer

Unit tests are great, but they don’t catch all bugs because they don’t test features like a user. Never fear! Let’s learn how to write robust, scalable Web UI tests using Python, pytest, and Selenium WebDriver that cover the full stack for any Web app.

Unit tests are a great way to start Web app testing and automation, but the buck doesn’t stop there. Black-box feature tests that interact with the app like a user are just as important. They catch things unit tests cannot. The challenge is that Web UI tests are complicated and notoriously unreliable. So, how can we write tests well?

In this tutorial, we’ll cover:

  • Using Python 3, pytest, and Selenium WebDriver to write tests like a pro
  • Modeling Web UI interactions with page objects
  • Deciding what should and should not be tested with automation
  • Improving the solution to scale higher

The tutorial will include lecture segments intertwined with hands-on coding exercises. We will write tests together for the DuckDuckGo website.

After this tutorial, you’ll be able to write battle-hardened Web UI tests for any Web app, including Django and Flask apps. You will also have a test automation project that can be the starting point for any Web UI tests.

Video

Prerequisites & Setup Instructions

All prerequisites and setup instructions can be found in the README of the tutorial project: https://github.com/AndyLPK247/pyohio-2019-web-ui-testing

Please follow these instructions and then clone the repository onto your machine. Please then bring your machine to the tutorial session -- we will be hands-on with code!

Presented by: