On Sun, Oct 06, 2002 at 11:57:51PM -0400, Noah White wrote:
>       I wouldn't call it a dirty little secret as Michael put it :-).  
>       This is the right thing to do within the context of a contract. The 
> contract does not guarantee that method functionality implemented by a 
> concrete class does exactly a certain thing a certain way ( I'd like to see 
> the language that does!).

Oddly enough, JUnit (and in the Perl world Test::Class and Test::Unit) can
do it with inherited tests.  Subclasses must pass their parent's tests, so
yes, you can guarantee method implementations, just not with an interface
contract.

Unfortunately, Java doesn't ship with JUnit nor do Java libraries usually
ship with tests nor does a simple convention to run them nor an expectation
that the user will run the tests before installing.  Score one for Perl. :)


-- 

Michael G. Schwern   <[EMAIL PROTECTED]>    http://www.pobox.com/~schwern/
Perl Quality Assurance      <[EMAIL PROTECTED]>         Kwalitee Is Job One
Please Captain, not in front of the Klingons.

Reply via email to