Thursday 1:20 p.m.–4:40 p.m.
Improving automated testing with py.test
- Audience level:
Many people learn testing through the JUnit/PYUnit paradigm. Lately, py.test's new fixture mechanisms have gained traction among many Pythonistas. This tutorial explores py.test discusses key strategies how to benefit from using py.test for your existing unittest/nose based code bases.
Testing is essential for code quality. Tests need to be automated and regularly run to benefit from them. Frameworks such as pytest are based on many years of exercise and help you apply best practices to your tests. Apart from integrating well with existing unittest/nose test suites, pytest offers some unique features for writing and organising your test code. In six steps we introduce main features of py.test, with a strong focus on best-practise organisation of test fixtures and code. We discuss key strategies for using py.test with existing unittest/nose code bases and how to incrementally make use of py.test mechanisms.
No handouts have been provided yet for this tutorial