Code/test ratio wrt static vs dynamic typing [was: Re: Python Success stories]

greg greg at cosc.canterbury.ac.nz
Tue May 20 23:01:55 EDT 2008


Someone wrote:
>>>I'm just curious whether this
>>>argument against dynamic typing - that you end up doing the job of a
>>>static compiler in test code - holds in practice.

I suspect that, although some of the things caught
by the tests would be caught by static typing, the
very *same* tests are also catching a lot of things
that wouldn't be caught by static typing.

Also, I don't think it's valid to equate the size of
the tests with the amount of effort it took to develop
them. For instance, the test suite for Pyrex is currently
larger than the Pyrex compiler, but I've still spent
far more time and effort developing the compiler than
writing the tests.

-- 
Greg



More information about the Python-list mailing list