Establishes a “mock” request environment suitable for running tests in.
| Type | Name and description | 
|---|---|
| static java.lang.String | DEFAULT_CONTROLLER_NAME | 
| org.springframework.context.ApplicationContext | applicationContext | 
| Constructor and description | 
|---|
| GrailsTestRequestEnvironmentInterceptor
                                (org.springframework.context.ApplicationContext applicationContext) | 
| Type | Name and description | 
|---|---|
| void | destroy()Removes the mock request environment | 
| void | doInRequestEnvironment(groovy.lang.Closure body)Passes bodytodoInRequestEnvironment(String,Closure)with theDEFAULT_CONTROLLER_NAME. | 
| void | doInRequestEnvironment(java.lang.String controllerName, groovy.lang.Closure body)Calls init()before anddestroy()after invokingbody. | 
| void | init(java.lang.String controllerName = DEFAULT_CONTROLLER_NAME)Establishes a mock request environment | 
| Methods inherited from class | Name | 
|---|---|
| class java.lang.Object | java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() | 
Removes the mock request environment
 Passes body to doInRequestEnvironment(String,Closure) with the DEFAULT_CONTROLLER_NAME.
     
 Calls init() before and destroy() after invoking body.
     
Establishes a mock request environment
Groovy Documentation