Closed kierankelleher closed 12 years ago
Thanks for sharing the patch. I didn't know Wonder had an extension mechanism for prototypes. I watched your screen cast about that, and I've written some tests to make sure this feature doesn't break in the future. Additionally, I've removed some tests for the TemporaryEditingContext
since they make no sense anymore. Thanks again and apologies for taking so long to answer.
When ERXExtensions (principal class) loads in a Wonder app, it sets itself as the class delegate for EOModelGroup such that EOModelGroup.defaultGroup() method is delegated to ERXExtensions. This in turn will enable the use of Extended Prototypes.
Along with this change, properties need to be set before the model loads for a test: er.extensions.ERXModelGroup.modelClassName = com.webobjects.eoaccess.ERXModel er.extensions.ERXModel.useExtendedPrototypes = true er.extensions.ERXModelGroup.flattenPrototypes = false
Without this patch, entities depending on the use of extended prototypes will not be initialized properly.
Henrique, if you think this should be implemented some other way, then by all means do so.