Support LoadBalancer child context creation during AOT processing (#1135)

This commit is contained in:
Olga Maciaszek-Sharma
2022-08-11 17:00:33 +02:00
committed by GitHub
parent 6e610bf5c9
commit 94ab8728fb
8 changed files with 402 additions and 46 deletions

View File

@@ -38,6 +38,7 @@ import static org.assertj.core.api.BDDAssertions.then;
/**
* @author Spencer Gibb
* @author Tommy Karlsson
* @author Olga Maciaszek-Sharma
*/
public class NamedContextFactoryTests {
@@ -86,8 +87,8 @@ public class NamedContextFactoryTests {
then(barBazes.size()).as("barBazes size was wrong").isEqualTo(2);
// get the contexts before destroy() to verify these are the old ones
AnnotationConfigApplicationContext fooContext = factory.getContext("foo");
AnnotationConfigApplicationContext barContext = factory.getContext("bar");
GenericApplicationContext fooContext = factory.getContext("foo");
GenericApplicationContext barContext = factory.getContext("bar");
then(fooContext.getClassLoader()).as("foo context classloader does not match parent")
.isSameAs(parent.getClassLoader());