Re: Need Urgent Help
Ulrich Eckhardt wrote:
Jinsu Jais wrote:
So my friends, PLEASE HELP ME TO MAKE A PERFECT ERROR-FREE
PROJECT.
Two steps:
- define 'error-free'
- create tests that assure error-freeness
- modify program until it passes all tests
That's not always possible. There are types of errors that
simply aren't testable, at least not easily. You expect a
program to signal errors due to hardware problems on the disk,
for example, but you don't always have the means to simulate
such errors. And as soon as threading is involved, the actual
error may require very subtle timing conditions to appear.
I'd say that to start with, of course, you have to define very
precisely what the program should do, in all cases---I suspect
that this is what you mean by "define error-free". After that,
careful code review AND an extensive test suite are necessary,
but in general, a test should never fail. If it does, it means
that there is a weakness in your code review proceedure.
In practice, of course, tests do fail, because no code review
proceedure is perfect. But in a well run shop, every test
failure results in a modification of the code review proceedure,
so that it won't happen again.
-- `
James Kanze Gabi Software email: kanze.james@neuf.fr
Conseils en informatique orient?e objet/
Beratung in objektorientierter Datenverarbeitung
9 place S?mard, 78210 St.-Cyr-l'?cole, France, +33 (0)1 30 23 00 34
--
[ See http://www.gotw.ca/resources/clcm.htm for info about ]
[ comp.lang.c++.moderated. First time posters: Do this! ]