Prior to this commit, test AOT processing failed when using the GraalVM tracing agent and GraalVM Native Build Tools (NBT) plugins for Maven and Gradle. The reason is that the AOT support in the TestContext framework (TCF) relied on AotDetector.useGeneratedArtifacts() which delegates internally to NativeDetector.inNativeImage() which does not differentiate between values stored in the "org.graalvm.nativeimage.imagecode" JVM system property. This commit addresses this issue by introducing a TestAotDetector utility that is specific to the TCF. This detector considers the current runtime to be in "AOT runtime mode" if the "spring.aot.enabled" Spring property is set to "true" or the GraalVM "org.graalvm.nativeimage.imagecode" JVM system property is set to any non-empty value other than "agent". Closes gh-30281 |
||
|---|---|---|
| .. | ||
| src | ||
| .springBeans | ||
| spring-test.gradle | ||