mirror of
https://github.com/spring-projects/spring-framework
synced 2026-06-08 17:33:33 +00:00
38a56b3fda
Prior to this commit, when ReflectionTestUtils was used to invoke a method on a CGLIB proxy, the invocation was always performed directly on the proxy. Consequently, if the method was not proxied/intercepted by the CGLIB proxy -- for example, if the method was final or effectively private -- the invoked method could not operate on the state of the target object or interact with other private methods in the target object. With this commit, if the supplied target object is a CGLIB proxy which does not intercept the method, the proxy will be unwrapped allowing the method to be invoked directly on the ultimate target of the proxy. Closes gh-33429