Talk
Testing as a Container - Using docker with selenium
Selenium Conference India 2016 in Bangalore: shipping tests as containers so a Selenium suite moves with its infrastructure.
24 July 2016 · 2 min · Irfan Ahmad · Selenium Conference India 2016, Bangalore
I spoke and demonstrated “Testing as a Container - Using docker with selenium and friends in testing” at Selenium Conference 2016 in Bangalore on 24 July 2016. The room was large, and the questions were about how the setup actually runs.
Purpose
Ship tests as containers, not as a folder of code that only runs on one laptop.
Testers own the reliability of their tests in the same way developers and the people running production own the software. That is usually difficult, slow, and dependent on a developer being free. Docker is one way to make the test environment something you can build, move, and throw away.
Need
Two trends were already visible in how software was being delivered:
- Docker was becoming the usual way to manage infrastructure with containers.
- Test code and the infrastructure under it were growing: more complexity, more dependencies, more languages, and a demand for reliability and speed at the same time.
Agenda
The session was about using containers for a growing test stack and for continuous delivery:
- What a container is, and how that applies to test automation.
- How Docker can shorten a run, make a clean environment cheap to set up, and shrink the gap between development, acceptance, and production.
- Examples that put a whole testing stack, Selenium included, in containers.
- Running the test container next to the application containers so a delivery pipeline stays manageable.
- Practices that keep a Docker setup from becoming another machine only one person can rebuild.
What you should leave with
- A working picture of Docker, and why a tester should care.
- Enough of a Dockerfile and Compose file to read a multi-container setup.
- A path for packaging an existing Selenium suite, or another runner, as a container you can move.
- A Selenium example you can take back to a project.
- A place to put those containers on a CI pipeline.
Demo and hands-on
- Slides: testing-container
- teststack, the project opened for the demo
- Demo video
- Talk video
The original notes asked for feedback if the hands-on broke. The repository is still the place to look.
People
The other useful part of the two days was the corridor: attendees from other cities, old friends, and other speakers with a concrete idea rather than a product pitch.
Ported from irfanahmad.in. Original URL