mirror of
https://github.com/spring-projects/spring-boot.git
synced 2024-08-29 03:06:45 +08:00
3f7bf7d34f
Update `SpringBootContextLoader` so that when possible the `SpringApplication` remains in control of creating the `Environment` instance. Prior to this commit, we would always create the `Environment` in the `SpringBootContextLoader` and then call `setEnvironment` on the `SpringApplication`. This meant that the `ApplicationEnvironment` classes were not used and that `isCustomEnvironment` was set to `true` so no conversion was applied. With the updated code, an `ApplicationListener` is used to mutate the `Environment` instance and add the required test property sources. Fixes gh-29169 |
||
---|---|---|
.. | ||
src | ||
application.yml | ||
build.gradle |