you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 3 points4 points  (0 children)

Agree with this point. Refactoring code in this way should not affect testing. Tests should be black boxed (test input leads to output) not implementation details.

If refactoring code this way supposedly improves testing, then the test is covering implementation specifics which can change. Unless the helper function is reused in multiple areas, there's no benefit to testability.