Class SpringCustomContextLoader
- java.lang.Object
-
- de.hybris.platform.basecommerce.util.SpringCustomContextLoader
-
public class SpringCustomContextLoader extends java.lang.Objectbased onTestContext
-
-
Constructor Summary
Constructors Constructor Description SpringCustomContextLoader(java.lang.Class testClazz)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidloadApplicationContextByConvention(org.springframework.context.support.GenericApplicationContext globalCtx)voidloadApplicationContexts(org.springframework.context.support.GenericApplicationContext globalCtx)protected java.lang.String[]retrieveContextLocations(org.springframework.test.context.ContextLoader contextLoader, java.lang.Class<?> clazz)RetrieveApplicationContextresource locations for the suppliedclass, using the suppliedContextLoadertoprocessthe locations.
-
-
-
Method Detail
-
loadApplicationContexts
public void loadApplicationContexts(org.springframework.context.support.GenericApplicationContext globalCtx) throws java.lang.Exception- Throws:
java.lang.Exception
-
loadApplicationContextByConvention
public void loadApplicationContextByConvention(org.springframework.context.support.GenericApplicationContext globalCtx)
-
retrieveContextLocations
protected java.lang.String[] retrieveContextLocations(org.springframework.test.context.ContextLoader contextLoader, java.lang.Class<?> clazz)RetrieveApplicationContextresource locations for the suppliedclass, using the suppliedContextLoadertoprocessthe locations.Note that the
inheritLocationsflag of@ContextConfigurationwill be taken into consideration. Specifically, if theinheritLocationsflag is set totrue, locations defined in the annotated class will be appended to the locations defined in superclasses.- Parameters:
contextLoader- the ContextLoader to use for processing the locations (must not benull)clazz- the class for which to retrieve the resource locations (must not benull)- Returns:
- the list of ApplicationContext resource locations for the specified class, including locations from superclasses if appropriate
- Throws:
java.lang.IllegalArgumentException- if@ContextConfigurationis not present on the supplied class
-
-