title: FilterChainProxy doesn't autowire
body: <p>I write so code:</p>
  
  <pre><code>@ContextConfiguration(locations = { "classpath:/test/BeanConfig.xml" })
  @RunWith(SpringJUnit4ClassRunner.class)
  //@WebAppConfiguration
  public class CandidateControllerTest {
  
      @Autowired
      FilterChainProxy springSecurityFilterChain;
      ...
  }
  </code></pre>
  
  <p>Where I must write something that this code works?</p>
  
  <p>stackTrace:</p>
  
  <pre><code> ERROR: org.springframework.test.context.TestContextManager - Caught exception while allowing TestExecutionListener [org.springframework.test.context.support.DependencyInjectionTestExecutionListener@48834af6] to prepare test instance [controllers.CandidateControllerTest@23ae81ab]
      org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'controllers.CandidateControllerTest': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: org.springframework.security.web.FilterChainProxy controllers.CandidateControllerTest.springSecurityFilterChain; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [org.springframework.security.web.FilterChainProxy] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}
          at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:288)
          at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1116)
          at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireBeanPr
  ....
  </code></pre>
  
  <p>I have bad understanding spring configuration. Please help.</p>
  
  <p><strong>UPDATE</strong></p>
  
  <p>post configuration files:</p>
  
  <p>BeanConfig.xml: </p>
  
  <pre><code> &lt;?xml version="1.0" encoding="UTF-8"?&gt;
      &lt;beans xmlns="http://www.springframework.org/schema/beans"
          xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:aop="http://www.springframework.org/schema/aop"
          xmlns:context="http://www.springframework.org/schema/context"
          xmlns:jee="http://www.springframework.org/schema/jee" xmlns:lang="http://www.springframework.org/schema/lang"
          xmlns:p="http://www.springframework.org/schema/p" xmlns:tx="http://www.springframework.org/schema/tx"
          xmlns:util="http://www.springframework.org/schema/util"
          xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
              http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop.xsd
              http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd
              http://www.springframework.org/schema/jee http://www.springframework.org/schema/jee/spring-jee.xsd
              http://www.springframework.org/schema/lang http://www.springframework.org/schema/lang/spring-lang.xsd
              http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx.xsd
              http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util.xsd"&gt;
  
          &lt;!-- Включаем опцию использования конфигурационных аннотаций (@Annotation-based configuration)--&gt;
          &lt;context:annotation-config /&gt;
  
  
          &lt;context:component-scan base-package="com.epam.hhsystem.jpa" /&gt;
          &lt;context:component-scan base-package="com.epam.hhsystem.services" /&gt;
  
          &lt;!-- Файл с настройками ресурсов для работы с данными (Data Access Resources) --&gt;
          &lt;import resource="data.xml" /&gt;
  
      &lt;/beans&gt;
  </code></pre>
  
  <p>data.xml</p>
  
  <pre><code>&lt;?xml  version="1.0" encoding="UTF-8"?&gt;
  &lt;beans xmlns="http://www.springframework.org/schema/beans"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:aop="http://www.springframework.org/schema/aop"
      xmlns:context="http://www.springframework.org/schema/context"
      xmlns:jee="http://www.springframework.org/schema/jee" xmlns:lang="http://www.springframework.org/schema/lang"
      xmlns:p="http://www.springframework.org/schema/p" xmlns:tx="http://www.springframework.org/schema/tx"
      xmlns:util="http://www.springframework.org/schema/util"
      xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
          http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop.xsd
          http://www.springframework.org/schema/jee http://www.springframework.org/schema/jee/spring-jee.xsd
          http://www.springframework.org/schema/lang http://www.springframework.org/schema/lang/spring-lang.xsd
          http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx.xsd
          http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util.xsd"&gt;
  
  &lt;!-- Настраивает управление транзакциями с помощью аннотации @Transactional --&gt;
      &lt;tx:annotation-driven transaction-manager="transactionManager" /&gt;
  
      &lt;!-- Менеджер транзакций --&gt;
      &lt;bean id="transactionManager"
          class="org.springframework.orm.hibernate4.HibernateTransactionManager"&gt;
          &lt;property name="sessionFactory" ref="sessionFactory" /&gt;
      &lt;/bean&gt;
  
      &lt;!-- Непосредственно бин dataSource --&gt;
      &lt;bean id="dataSource"
          class="org.springframework.jdbc.datasource.DriverManagerDataSource"
          p:driverClassName="com.microsoft.sqlserver.jdbc.SQLServerDriver"
          p:url="jdbc:sqlserver://10.16.9.52:1433;databaseName=hhsystemTest;"
          p:username="userNew" 
          p:password="Pass12345" /&gt;
  
      &lt;!-- Настройки фабрики сессий Хибернейта --&gt;
      &lt;bean id="sessionFactory"
          class="org.springframework.orm.hibernate4.LocalSessionFactoryBean"&gt;
          &lt;property name="dataSource" ref="dataSource" /&gt;
          &lt;property name="configLocation"&gt;
              &lt;value&gt;classpath:test/hibernate.cfg.xml&lt;/value&gt;
          &lt;/property&gt;
  
          &lt;property name="hibernateProperties"&gt;
              &lt;props&gt;
                  &lt;prop key="hibernate.show_sql"&gt;true&lt;/prop&gt;
                  &lt;prop key="hibernate.dialect"&gt;org.hibernate.dialect.SQLServerDialect&lt;/prop&gt;
                  &lt;prop key="hibernate.connection.charSet"&gt;UTF-8&lt;/prop&gt;
  &lt;!--                &lt;prop key="hibernate.hbm2ddl.auto"&gt;create-drop&lt;/prop&gt; --&gt;
          &lt;/props&gt;
          &lt;/property&gt;
      &lt;/bean&gt;
  
  &lt;/beans&gt;
  </code></pre>
  
  <p>what configurations needs for working my application?</p>