Based on Test Driven Development with Python book