Click here to Skip to main content
15,887,442 members

Welcome to the Lounge

   

For discussing anything related to a software developer's life but is not for programming questions. Got a programming question?

The Lounge is rated Safe For Work. If you're about to post something inappropriate for a shared office environment, then don't post it. No ads, no abuse, and no programming questions. Trolling, (political, climate, religious or whatever) will result in your account being removed.

 
AnswerRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
pkfox27-Jan-22 6:43
professionalpkfox27-Jan-22 6:43 
AnswerRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
Gerry Schmitz27-Jan-22 7:02
mveGerry Schmitz27-Jan-22 7:02 
AnswerRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
kmoorevs27-Jan-22 7:02
kmoorevs27-Jan-22 7:02 
AnswerRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
Greg Utas27-Jan-22 7:07
professionalGreg Utas27-Jan-22 7:07 
AnswerRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
theoldfool27-Jan-22 7:09
professionaltheoldfool27-Jan-22 7:09 
AnswerRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
Marc Clifton27-Jan-22 7:53
mvaMarc Clifton27-Jan-22 7:53 
JokeRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
0x01AA27-Jan-22 8:48
mve0x01AA27-Jan-22 8:48 
AnswerRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
trønderen27-Jan-22 9:00
trønderen27-Jan-22 9:00 
My experience is that most test frameworks rapidly grows into such a complexity that you spend far more time on all the required red tape than on developing good tests. It may pay for huge systems that will be in development for many years, by scores of developers, but for smaller systems, you can do 99% of the same amount of testing with a much simpler infrastructure, with far less test management.

Certainly: Do systematic testing! And have a setup that allows you to play old tests again - a.k.a. regression testing. Just don't let the testing infrastructure completely take over.

The important tasks in testing is not managing the tests, but rather to identify relevant test cases. All corner cases - and sometimes the cartesian product of all possible cases (when the product is within reasonable limits). How to provoke synchronizing and timing issues. Identify relevant stress testing. And so on. I have seen cases where far more time was spent on test management than on developing relevant tests.

Regression testing is essential (and I am surprised by how often I see new software releases witn regression from earlier releases!), but sometimes I wonder if it is getting out of hand: Some years ago, I worked in a development environment having collected regression tests for many years. Before a release, we started the test suite before going home on Friday evening, hoping that it would complete before Monday morning ten days later. So for bugs/fails reported by that week (++) run, there was a ten day turnaround. We invested in the very fastest Sun machine available on the market, cutting the time to complete the tests started on Friday afternoon to complete some time on the (first) following Monday, a week earlier than with the old setup.

Yet I was asking myself if we should possibly consider reducing the amount of regression testing, or trying to make the structure more efficient. Fact is that continuous unit, module and system tests regularly applied during development were so complete that the week long (later: weekend long) regression test run practically never revealed any problems.

In later jobs, I have seen tests requiring magnitudes more power than they should have, due to lack of proper unit and module tests. Or rather: Management of such. The developers do not trust that units have been properly tested, so in every module where the unit is used, the unit tests are run again, 'in this context'. Then for every (sub)system referencing a module, all the module tests are repeated, repeating all the unit tests ... and so on. The whole thing is repeated for each possible configuration / platform. The developers are completely deaf to proposals for managing tests in a way where you have some trust in the tests done the previous day of some unit that hasn't been modified for a month and has been tested in that configuration you are asking for about fifty times since. Any proposal for a more resource friendly test regime is, by the developers, considered an inappropriate interference with their 'professional' work. So, in my last job, any commit required several times the resources of the compilation and building, in doing all the testing that the developers insisted on.

Testing is fundamental to software quality. Yet I have seen so many crazy ways of doing it that I tend to sharpen my claws every time someone insists on spending even more resources on even more expensive (both monetary and in learning and managing) even more complex test infrastructures.

Testing should be relativistic: Make it as simple as necessary, but no simpler.
AnswerRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
Slacker00727-Jan-22 9:40
professionalSlacker00727-Jan-22 9:40 
JokeRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
englebart5-Feb-22 5:11
professionalenglebart5-Feb-22 5:11 
AnswerRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
TNCaver27-Jan-22 9:57
TNCaver27-Jan-22 9:57 
GeneralRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
MarkTJohnson27-Jan-22 10:29
professionalMarkTJohnson27-Jan-22 10:29 
GeneralRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
Ravi Bhavnani27-Jan-22 10:47
professionalRavi Bhavnani27-Jan-22 10:47 
GeneralRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
lmoelleb27-Jan-22 20:59
lmoelleb27-Jan-22 20:59 
GeneralRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
TNCaver28-Jan-22 6:07
TNCaver28-Jan-22 6:07 
GeneralRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
lmoelleb29-Jan-22 4:52
lmoelleb29-Jan-22 4:52 
AnswerRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
Ravi Bhavnani27-Jan-22 10:44
professionalRavi Bhavnani27-Jan-22 10:44 
AnswerRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
r_hyde27-Jan-22 10:46
r_hyde27-Jan-22 10:46 
AnswerRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
Mycroft Holmes27-Jan-22 11:31
professionalMycroft Holmes27-Jan-22 11:31 
GeneralRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
lmoelleb27-Jan-22 20:48
lmoelleb27-Jan-22 20:48 
AnswerRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
Gary R. Wheeler27-Jan-22 15:31
Gary R. Wheeler27-Jan-22 15:31 
AnswerRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
ZevSpitz27-Jan-22 21:25
professionalZevSpitz27-Jan-22 21:25 
AnswerRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
RustyF27-Jan-22 21:24
RustyF27-Jan-22 21:24 
AnswerRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
lmoelleb27-Jan-22 21:07
lmoelleb27-Jan-22 21:07 
AnswerRe: I'm fairly old fashioned at times ... but should I embrace unit testing? Pin
Davyd McColl27-Jan-22 21:48
Davyd McColl27-Jan-22 21:48 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.