Keep your Source Close and your Unit Tests Closer

后端 未结 7 465
既然无缘
既然无缘 2021-01-03 05:12

When I first started using unit tests I encountered two problems. First was being able to test private methods and fields and second falling behind on keeping unit tests up

7条回答
  •  说谎
    说谎 (楼主)
    2021-01-03 05:51

    I think that's not what unit tests were designed for. If you have developed code quickly and your unit tests are behind, then they will fail of course, but this shouldn't lead you to use black magic, but to write the unit tests. If you don't like this way, then you shouldn't use unit tests at all.

提交回复
热议问题