Saturday 4:30 p.m.–5 p.m.

Advanced techniques for Web functional testing

Julien Phalip

Audience level:
Intermediate
Category:
Testing

Description

This talk will present multiple advanced techniques for Web functional testing. You will learn how to test a wide range of Web front-end components, such as CSS, visuals, responsive designs and user interactions — all using Python. Various practical tips will also be presented to harness your functional tests in real project workflows.

Abstract

The Python Web ecosystem has always placed a strong emphasis on testing, partly thanks to a wide range of testing tools available in Python Web frameworks. Some of the most used from those tools are dummy web clients, which allow to emit mock HTTP requests directly to your codebase and to inspect the responses' contents. However, as useful as they are, these dummy clients are limited as they do not exercise the full HTTP specification and they cannot effectively reproduce actual user interactions. With the recent advent of browser automators such as Selenium, it is now possible to use sophisticated HTTP clients to execute your tests in a more comprehensive way. Indeed, this allows you to write functional tests to ensure that all layers of your web application properly fit together and that user interactions function well from end to end. Python Web developers are already becoming increasingly familiar with Selenium et al., therefore this talk will go far beyond just an introduction to those technologies. Thus, I will present advanced techniques for testing CSS, visuals and responsive designs — all using Python. I will also offer advice on how to harness functional tests within real project workflows, in particular in a continuous integration environments. Lastly, functional tests are often criticized for being too slow and too brittle. Therefore I will present various practical tips for making functional tests faster and more robust.