[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Dpkg testing framework and Ubuntu's automated testing

Russ Allbery writes ("Re: Dpkg testing framework and Ubuntu's automated testing"):
> I don't think I've ever found a piece of software where I didn't want to
> write unit tests -- there aren't any internal data structure
> implementations, internal functions (such as dependency analysis) with a
> well-defined API, or anything similar?

The data structure and file I/O code is pretty shallow, and like most
of the program it is very close to the surface.  When I want to test
the dependency analysis (say) this can easily be done from outside the
complete program by setting up a suitable test environment or test

But then I usually write my programs so that the important internal
interfaces can be exercised from the outside just because that makes
them more flexible, which sort of seems to evade part of your
definition of unit test (the idea that a unit test is something which
you perform on the program's pieces, rather than any test which
exercises a particular piece in a controlled way).


Reply to: