On Feb 7, 2008, at 11:27 AM, Christian Heimes wrote: > You are correct. Normally interfaces are only validated in unit tests. > The validation function of zope.interface checks if a class implements > or object provides the promised methods and attributes. It also > compares > the method signatures.
Note also that checking the "class implements" is frequently problematic since the verification doesn't know what the factory does to the object (where the factory is the constructor provided by the class in most cases). We frequently test instances this way in unit tests. -Fred -- Fred Drake <fdrake at acm.org> _______________________________________________ Python-3000 mailing list [email protected] http://mail.python.org/mailman/listinfo/python-3000 Unsubscribe: http://mail.python.org/mailman/options/python-3000/archive%40mail-archive.com
