Get the latest tech news
How to test without mocking
Mocking is an Anti-Pattern - ways for better tests without mocking
Refactoring all you your (more complex) IF conditionals into their own functions, make the code easier to understand and you can write meaningful tests. At one company we put expensive hard drives and sound isolation into developer machines, to speed up testing. Or as Greenspun’s tenth rule puts it: “Any sufficiently complicated C or Fortran program contains an ad hoc, informally-specified, bug-ridden, slow implementation of half of Common Lisp.”
Or read this on Hacker News