Spring Framework has a TestAotProcessor that is invoked by Spring Boot's build plugins to trigger the optimization of test contexts. There is a similar arrangement for the application, but it currently resides in Spring Boot.

The current asymmetry is a bit odd and it would be nice if we offered the same level of customization in both cases. If Spring Boot has specific needs, we can provide protected callbacks.