This issue picks up where
SPR-5243 left off. Specifically this issue focuses on adding support for WebApplicationContext hierarchies within single test classes as well as within test class hierarchies.
- Ensure that common WAC hierarchies can be configured in integration tests (e.g., root and dispatcher WACs in a parent-child relationship).
- Ensure that hierarchies of WACs can be configured using @ContextHierarchy (see
- Ensure that the type of the root WAC can differ from that of its parent (e.g., a standard ApplicationContext loaded for an EAR)
- Set a loaded context as the ROOT_WEB_APPLICATION_CONTEXT_ATTRIBUTE in the MockServletContext when context hierarchies are used:
- if an ApplicationContext has no parent and the context is a WAC, set the context as the root WAC
- if an ApplicationContext has a parent that is not a WAC and the context itself is a WAC, set the context as the root WAC
In ExtendedControllerIntegrationTests the configuration for the root WAC will be overridden, and the configuration for the dispatcher WAC will be merged.