How to have PersistentEntityResourceAssembler injected into request methods of custom @RepositoryRestController in a @WebMvcTest unit test
Overview How can I have a PersistentEntityResourceAssembler properly injected into my custom REST controller's request methods during a @WebMvcTest unit test? First SO question. Apologies in advance, probably just missing something stupid. Sample code available on GitHub . Oliver Gierke, where you at? :P Details I have a custom REST controller annotated with @RepositoryRestController . Some of its request methods have a PersistentEntityResourceAssembler injected as an argument so I can return HAL resources. @RepositoryRestController @RestController @RequestMapping(produces = MediaTypes.HAL