Description
My intention with this talk is to help people understand how tests can help us write better code and how it can guide our designs. In this opportunity I'll show how to do this using pytest, and get most of its power.
I'm a Python developer who also happens to have written some Java, which has a strong influence in how mocks came to be, and this has influenced my way of testing.
Combine this with a sudden motivation to start doing TDD, and I'd say there's a lot to be shared.
I will show different pytest features and how they can assist us in writing easier, and understandable tests.
Overview
- Some words about testing
- Understanding the core of pytest
- Tests as documentation
- Fixtures
- Parametrize
- Mocks / Understanding mocks / Using mocks
- Refactoring with tests in mind
- TDD
- Plugins