|
From: Paul B. <eye...@gm...> - 2006-05-26 18:04:04
|
I think the confusion here is in the way the article is written... what I read from it is not that I need to test an interface, but I need to make sure that when I test a class that implements an interface I should make sure that the tests confirm the functional intention of the interface... The way he does this is to say write an abstract class which correlates to the *intention* of the interface, and write tests against that, then with the specific implementation of the class, write tests against that. So, I think what John Mark was actually asking is: "How do run the test methods written against a superclass in by subclass te= st" which I think, Peter, you looked at over here (although the example I found relies on your event driven implementation of asunit).... On 5/26/06, John Mark Hawley <ma...@ni...> wrote: > rationale: http://www.placebosoft.com/abstract-test.html > > Basically, while the compiler tests that interfaces are correct syntactic= ally, having a set of tests to run on an interface means that you can verif= y that each interface method is actually doing what it should be in a coher= ent, meaningful way. > > Without an interface test, I can be sure that HamSandwich implements IFoo= d, but I can't be sure the IFood method eat() doesn't turn the HamSandwich = into a tree, when for all other IFoods eat() causes the IFood to dissappear= . > > -john mark hawley > > Why are you testing interfaces? > Perhaps you can identify some kind of value that I can't see? > > Peter > > > > > > _______________________________________________ > Asunit-users mailing list > Asu...@li... > https://lists.sourceforge.net/lists/listinfo/asunit-users > |