|
Re: Broken Dependencies
|
Posted: Jun 18, 2007 3:32 AM
|
|
> While testing is definitely a Good Thing, having something > like design-time or compile-time checking is better still. > I shouldn't have to package, deploy and start up my web > b app, and then run an integration testing suite, just to > find out that I typed foo.getFar() in my > template, when Foo only has a getBar() > method.
Depends on the cost. How much extra declarations do you need to add to get the checks, how often are these in the way of legitimate changes, and what programming methods do you lose by the forced mapping to known methods?
Of course, if checking for this is free, then it is of course better to get it at compile or design time. If the cost is higher than 0, then it is a trade off. (For instance, in Java I find that these checks come at a cost of 70%+ increase in code size compared to dropping all declarations and testing runtime, like Ruby does.)
|
|