AbstractTestRunner Class — spring-boot Architecture
Architecture documentation for the AbstractTestRunner class in SpringApplicationTests.java from the spring-boot codebase.
Entity Profile
Relationship Graph
Source Code
core/spring-boot/src/test/java/org/springframework/boot/SpringApplicationTests.java lines 1915–1953
abstract static class AbstractTestRunner implements ApplicationContextAware, Ordered {
private final String[] expectedBefore;
@SuppressWarnings("NullAway.Init")
private ApplicationContext applicationContext;
private final int order;
private boolean run;
AbstractTestRunner(int order, String... expectedBefore) {
this.expectedBefore = expectedBefore;
this.order = order;
}
@Override
public void setApplicationContext(ApplicationContext applicationContext) {
this.applicationContext = applicationContext;
}
@Override
public int getOrder() {
return this.order;
}
void markAsRan() {
this.run = true;
for (String name : this.expectedBefore) {
AbstractTestRunner bean = this.applicationContext.getBean(name, AbstractTestRunner.class);
assertThat(bean.hasRun()).isTrue();
}
}
boolean hasRun() {
return this.run;
}
}
Domain
Source
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free