Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Yes, agreed. What the parent is saying about

> only ever use an interface, never the real implementation + mockgen the mocks based on this interface + use the mocks to assert that a function is called, with exactly this parameters and in this exact order.

is not ideal, and that's what we don't do. We test the real implementation, then that becomes the contract. We assume the contract when we write the mocks.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: