The beginning of unit tests after the start of the project?

I took a project that has been ongoing for several months. I had never done unit tests and thought it would be a good time to start. However, as a rule, unit tests are written along the way, and you plan them when you start the project. Is it wise for me to start now? Are there any decent resources for creating unit tests without launching a completely new solution (the project is already underway). Using vb.net with VS2005

Thank you in advance:)

+3
source share
8 answers

At any time, the best time to start unit testing is, although it is becoming more difficult as you go further into the project, as you will find that things have become tightly coupled without considering the possibility of testing.

The best place to start is what you want to develop, or into critical sections that are currently facing a lot of problems. If you find that you have free time, try reformatting your code and adding tests to it.

You must use a separate project as part of the solution for your unit tests, so you do not need to distribute it with your application.

+5
source

Write tests for the code that you are touching right now. When you have time (yes, right), you can cover other parts of the program.

, ; , , , .

+2

, . , .

, : , , , , , . , , . , , .

, , , .

unit test .

Unit test - , .

+2

, , - , ,

  • , .
  • , .

. , unit test. Java, ++, C #. vb.net, , .

/ c2 wiki.

+2

:

  • .
  • , .
  • .

, .

+1

, .

, , , .

, , . , , .

0

Running this late unit test writing just means you will have much more room to write right now. It is worth it that IMO does not rush time, but, unfortunately, sometimes time / budget does not allow this.

0
source

Source: https://habr.com/ru/post/1708274/


All Articles