Stephan Richter wrote:
> In addition there is the FieldProperty class, which can be used to enforce a
> value. I have recently started to use it all the time. I really like it too.
It also sets the attributes to the default values inside the tests,
taking them from the interface definition instead of the class definition..
what = 42
what = Int(title=u"Whatever",default=42)
>>> from zope.interface.verify import verifyClass
>>> verifyClass(IMyObject, MyObject)
Try changing the attributes:
>>> obj = MyObject()
what = FieldProperty(IMyObject['what'])
Zope3-users mailing list