DEV Community

Discussion on: What are your biggest problems with unit testing?

Collapse
 
miniscruff profile image
miniscruff

Too many mocks can be a code smell. It could be your classes have too many dependencies or too many coupled pieces.

I also don't mock databases and will use a test one for each test run instead.

It could also be that you need more utility methods for testing.