5 ms·
Even with typed driven development you still want unit tests in the form of property based tests. Also a nice way to resolve the 10-50 lines issue is to follow
by exdsq 6y ago
Even with typed driven development you still want unit tests in the form of property based tests. Also a nice way to resolve the 10-50 lines issue is to follow the Arrange, Act, Assert pattern where you could look at the second block to see the actions. Move as much of the Arrange section into a setup and it should be a bit clearer :)
- Verdex 6y agoI really like property based tests. They feel like they're everything that unit tests without them were supposed to be. * More closely encodes the behavior you want the code to have * More likely to find weird edge cases where some input does something unexpected * Less work to get greater coverage