Class AbstractGenericWebContextLoader

All Implemented Interfaces:
ContextLoader, SmartContextLoader
Direct Known Subclasses:
AnnotationConfigWebContextLoader, GenericXmlWebContextLoader

public abstract class AbstractGenericWebContextLoader extends AbstractContextLoader
Abstract, generic extension of AbstractContextLoader that loads a GenericWebApplicationContext.

If instances of concrete subclasses are invoked via the SmartContextLoader SPI, the context will be loaded from the MergedContextConfiguration provided to loadContext(MergedContextConfiguration). In such cases, a SmartContextLoader will decide whether to load the context from locations or annotated classes. Note that AbstractGenericWebContextLoader does not support the loadContext(String... locations) method from the legacy ContextLoader SPI.

Concrete subclasses must provide an appropriate implementation of loadBeanDefinitions(, org.springframework.test.context.web.WebMergedContextConfiguration).

Sam Brannen, Phillip Webb
See Also: