spring-boot/spring-boot-project/spring-boot-test
Andy Wilkinson 52050c173c Fix spying on scoped beans with @SpyBean
Previously, when spying on a scoped bean the creation of the spy
would be performed using the scoped proxy. This would result in
the spy being unable to spy on any of the target bean's methods as
the scoped proxy's implementations of those methods would be final.

This commit updates MockitoPostProcessor so that the creation of the
spy and injection of the @SpyBean-annotated field is performed using
the scoped target. The scoped target has not be proxied so this
allows Mockito to spy on all of its methods.

Closes gh-17817
2019-08-23 19:03:08 +01:00
..
src Fix spying on scoped beans with @SpyBean 2019-08-23 19:03:08 +01:00
pom.xml Merge branch '2.0.x' into 2.1.x 2019-03-19 17:04:41 +00:00