title: springSecurityFilterChain cannot be null
body: <p>I'm working with Spring Boot 1.4.0.M2 and I have written the following test case to ensure the proper functioning of a controller with spring security.</p>
  
  <pre><code>@RunWith(SpringRunner.class)
  @WebMvcTest(HelloController.class)
  public class HelloControllerTest {
  
      @Autowired
      private WebApplicationContext wac;
  
      private MockMvc mockMvc;
  
      @Before
      public void setUp() {
          mockMvc = MockMvcBuilders
                  .webAppContextSetup(wac)
                  .alwaysDo(print())
                  .apply(springSecurity())
                  .build();
      }
  
      @Test
      public void getHelloShouldReturnWithCacheControlSet() throws Exception {
          this.mockMvc.perform(get("/hello")
                  .accept(MediaType.TEXT_PLAIN))
                  .andExpect(status().isOk())
                  .andExpect(content().string("Hello World!"))
                  .andExpect(header().stringValues("Cache-Control", "max-age=5"));
      }
  }
  </code></pre>
  
  <p>When I run the test, the following exception is thrown:</p>
  
  <pre><code>java.lang.IllegalStateException: springSecurityFilterChain cannot be null. Ensure a Bean with the name springSecurityFilterChain implementing Filter is present or inject the Filter to be used.
  </code></pre>
  
  <p>All other code can be found here: <a href="https://github.com/renewinkler84/http-cache-demo" rel="noreferrer">https://github.com/renewinkler84/http-cache-demo</a></p>
  
  <p>Why is this exception thrown? what else I have to configure?</p>