February 2022
Intermediate to advanced
274 pages
6h 28m
English
When people start working with parametrization, I’ve noticed that many tend to favor the technique they learned first—usually function parametrization—and seldom use the other methods.
Working through these exercises will help you learn how easy all three techniques are. Then later, in your own testing, you’ll be able to chose from three tools and select which is most useful to you at the time.
We’ve tested finish() already. But there’s another similar API method that needs testing, start():
| | def start(self, card_id: int): |
| | """Set a card state to 'in prog'.""" |
| | self.update_card(card_id, Card(state="in prog")) |
Let’s build some parametrized tests for it:
Write out three test functions that make sure ...
Read now
Unlock full access