• Andy Wilkinson's avatar
    Fix spying on scoped beans with @SpyBean · 52050c17
    Andy Wilkinson authored
    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
    52050c17
Name
Last commit
Last update
.bomr Loading commit data...
.github Loading commit data...
.mvn Loading commit data...
ci Loading commit data...
eclipse Loading commit data...
git/hooks Loading commit data...
spring-boot-project Loading commit data...
spring-boot-samples Loading commit data...
spring-boot-samples-invoker Loading commit data...
spring-boot-tests Loading commit data...
src/checkstyle Loading commit data...
.editorconfig Loading commit data...
.gitignore Loading commit data...
.settings-template.xml Loading commit data...
CODE_OF_CONDUCT.adoc Loading commit data...
CONTRIBUTING.adoc Loading commit data...
LICENSE.txt Loading commit data...
README.adoc Loading commit data...
SUPPORT.adoc Loading commit data...
mvnw Loading commit data...
mvnw.cmd Loading commit data...
pom.xml Loading commit data...