Agile programming (was Re: [P|C] Banksel)
Vitaliy email (remove spam text)
Olin Lathrop wrote:
>> It seems to me that the test function is almost always simpler than
>> the function being tested.
> I heartily disagree. There are definitely cases where testing and trying
> figure out whether the software is doing the best thing with the data is
> least as complicated as the operational software itself. These cases
> a lot more than "almost never".
You're the expert. :)
>> The classical example is a function that
>> uses a complex formula, and returns a value. You don't reproduce the
>> formula in the test function. It simply calls the user function, gets
>> a value, and compares it to a hand-calculated value.
> For small values of "tested". Many functions are too complicated be
> verified by a few simple input/output sets that can be generated by hand.
Perhaps we're talking about different things? The tests I have in mind,
normally test the high and low limits, plus some random value. For example,
the following functions could be tested using this method:
- Currency conversion
- ASCII to Unicode
- String to Hex
What types of functions do you have in mind?
See also: www.piclist.com/techref/microchip/devprogs.htm?key=programming
You must be a member of the
piclist mailing list
(not only a www.piclist.com member) to post to the