@@ -2890,13 +2890,13 @@ container and once through the aspect.
|
||||
[[aop-configurable-testing]]
|
||||
==== Unit testing @Configurable objects
|
||||
|
||||
One of the goals of the `@Configurable` support is to enable independent unit testing of
|
||||
domain objects without the difficulties associated with hard-coded lookups. If
|
||||
`@Configurable` types have not been woven by AspectJ then the annotation has no affect
|
||||
One of the goals of the `@Configurable` support is to enable independent unit testing
|
||||
of domain objects without the difficulties associated with hard-coded lookups.
|
||||
If `@Configurable` types have not been woven by AspectJ, the annotation has no affect
|
||||
during unit testing, and you can simply set mock or stub property references in the
|
||||
object under test and proceed as normal. If `@Configurable` types __have__ been woven by
|
||||
AspectJ then you can still unit test outside of the container as normal, but you will
|
||||
see a warning message each time that you construct an `@Configurable` object indicating
|
||||
see a warning message each time that you construct a `@Configurable` object indicating
|
||||
that it has not been configured by Spring.
|
||||
|
||||
|
||||
|
||||
@@ -547,7 +547,7 @@ The table below lists the available `HandlerExceptionResolver` implementations:
|
||||
codes based on the value in the annotation.
|
||||
|
||||
| `ExceptionHandlerExceptionResolver`
|
||||
| Resolves exceptions by invoking an `@ExceptionHandler` method in an `@Controller` or an
|
||||
| Resolves exceptions by invoking an `@ExceptionHandler` method in an `@Controller` or a
|
||||
`@ControllerAdvice` class. See <<mvc-ann-exceptionhandler,@ExceptionHandler methods>>.
|
||||
|===
|
||||
|
||||
@@ -2660,7 +2660,7 @@ to the model:
|
||||
===== Jackson JSONP
|
||||
|
||||
In order to enable http://en.wikipedia.org/wiki/JSONP[JSONP] support for `@ResponseBody`
|
||||
and `ResponseEntity` methods, declare an `@ControllerAdvice` bean that extends
|
||||
and `ResponseEntity` methods, declare a `@ControllerAdvice` bean that extends
|
||||
`AbstractJsonpResponseBodyAdvice` as shown below where the constructor argument indicates
|
||||
the JSONP query parameter name(s):
|
||||
|
||||
|
||||
Reference in New Issue
Block a user