Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

2
  • You must write very simple code then. The amount of reachable states in most modern systems mean that to do end-to-end testing would take the lifetime of the universe - testing two pieces each with 4bits of state takes 16 cases to test each, or 32 test cases in total; made into an end-to-end system gives 8bits of state or 256 test cases to cover all states. Personally, I'd rather do 1/8 the work. Commented May 25, 2015 at 20:59
  • 1
    @PeteKirkham the corollary of that is that you need to write a large number of unit tests and then also write the integration tests to make sure the unit still work with each other. The places I worked that were very fond of unit tests spent so much time writing (and maintaining) them that they dwarfed the codebase, and the amount of work they did was tiny in comparison to what I achieve outside that environment. Nothing is a magic bullet, I recommend trying to find a more pragmatic approach that gives you both test coverage of the important bits while also producing something. Commented May 25, 2015 at 22:05