Open
Description
We'd like to support something like this:
@MockitoSpyBean
ProxiedBean<Service> service;
ProxiedBean
would then provide accessors for the bean both with and without all of its Spring proxies. This should make it easier to bypass any caching or advice when, for example, setting expectations, while having them in place when exercising the service.
Hopefully this will address spring-projects/spring-boot#22281 by providing a nicer API that can be used in place of AopTestUtils.getTargetObject(service)
.