exceptions
Irmen de Jong
irmen at -nospam-remove-this-xs4all.nl
Mon May 31 10:40:55 EDT 2004
Zunbeltz Izaola wrote:
> Possibly the code should be restructered, and re-designed; there is
> always room for imporovement. But what I'm doing is not unittest. My
> program is controling and instrument (an x-ray powder
> diffractometer) and some parts of the instrument are not working for
> the moment, so i want to disable all error i get from this instrument
> (are coded like exceptions)
What I usually do in comparable situations is to write STUB code for
the parts of the system that don't work yet.
Write your stub code so that it does nothing, but doesn't raise any
exceptions too. The only thing you then have to do is write the rest
of the code as you would have done, and once the Stubbed parts work,
replace the stub code with the real code.
--Irmen
More information about the Python-list
mailing list