The idea that you can unit test all possible inputs and all the possible permutations of their internal interactions, and that this is enough to ensure proper type usage, is just naive.
No! I'm not.
I'm saying that if the input types to an algorithm are both type-checked & range-checked, then the ranges and types of the outputs will be consistant. There is no need to re-check those derived types and ranges. There is no need to check all possible permutations, only the boundary conditions--and thats a given.
A challenge: Demonstrate otherwise?
It makes the assumption that the design will be frozen and especially in a language like Perl where a simple bit of anti-social code like *{BrowserUK::ClassFullOfAwesome::tested_method} = sub { ... } is possible, that is a bad assumption.
You are suggesting that you need to protect against the possibility that someone will make modifications to production code to override methods at runtime. Why? So that you can tell them what they did wrong.
I guess our undestanding of what constitutes "production code" varies.
In reply to Re^10: OO automatic accessor generation
by BrowserUk
in thread OO automatic accessor generation
by Neighbour
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |