-
Notifications
You must be signed in to change notification settings - Fork 934
Fix determination of interface proxies #2070
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Change invocation of IProxyFactory.PostInstantiate to pass correct base class depending on the set interface proxy
This comment has been minimized.
This comment has been minimized.
src/NHibernate.Test/NHSpecificTest/GH2067/BaseClassAndDerivedInterfaceProxiesFixture.cs
Outdated
Show resolved
Hide resolved
I think tests for this PR better to place in StaticProxyTest folder/subfolder. |
I'm going to drop @bahusoid's tests as I believe the existing test cases do cover the required cases. |
public void PostInstantiate(string entityName, System.Type persistentClass, ISet<System.Type> interfaces, | ||
MethodInfo getIdentifierMethod, MethodInfo setIdentifierMethod, | ||
IAbstractComponentType componentIdType) | ||
{ | ||
//6.0 TODO: throw NotSupportedException |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Strange TODO inside obsolete method. Shouldn't we simply drop this method in 6.0? And when obsoleting something we also tend to add //Since 5.3 comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It’s not strange. This method would stay on the class (with additional argument) because of the interface, but shall not be supported.
Yeah, I’ve forgot about “since 5.3”
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's not so obvious that new override is meant. But why don't add override now?
Regarding dropping my tests. I'm fine wit it - I've added them with the wrong idea for "interface proxy" work. So they are at least excessive. But I still think that tests should be moved to StaticProxyTest |
The logic determining if we have an interface proxy or not moved to the tuplizer.
Fixes #2067