This is the mail archive of the mauve-discuss@sources.redhat.com mailing list for the Mauve project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Testing Abstract Classes


--- Daryl Lee <dlee@altaregos.com> wrote:
> I ran JDK 1.1 tests of FileReader before noticing it
> was an abstract class.
> Since an abstract class can't be instantiated, is
> the notion of testing it
> meaningful?  If so, what would be a good general
> approach?  Pending an
> answer, I'm going to skip over this and all other
> abstracts.  

You can create a wrapper class with stubbed abstract
methods, and use that to test the conditions on the
non-abstract methods hold. I've written some tests for
java.io.Reader in kaffe's regression test suite that
way.

best regards,

dalibor topic

__________________________________________________
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
http://mailplus.yahoo.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]