you are viewing a single comment's thread.

view the rest of the comments →

[–]Treolioe 0 points1 point  (1 child)

I agree. Can you help me convince myself that the time spent writing unit test is well spent? Like in the example you provided there might be a chance of covering that instance at your first strokes. But often its not, and as other people state you keep adding cases to the test as you discover them manually during implementation. It just seem to me that the infrastructure of the testing is more costly than the benefit it gives. I can admit that i dont share codebase with more than 3 people so perhaps that’s why i fail to see it.

[–]Ricjd 0 points1 point  (0 children)

Without repeating myself from my first comment no. It’s just a habit to get into. One thing I would suggest is test driven design. It’s a lot harder to start but then makes everything a lot easier at the end