Package org.springframework.context.support

Examples of org.springframework.context.support.ClassPathXmlApplicationContext.containsBean()


  }

  public void testNonMatchingResourcePattern() {
    ApplicationContext context = new ClassPathXmlApplicationContext(
        "org/springframework/context/annotation/nonMatchingResourcePatternTests.xml");
    assertFalse(context.containsBean("fooServiceImpl"));
  }

  public void testMatchingResourcePattern() {
    ApplicationContext context = new ClassPathXmlApplicationContext(
        "org/springframework/context/annotation/matchingResourcePatternTests.xml");
View Full Code Here


  }

  public void testMatchingResourcePattern() {
    ApplicationContext context = new ClassPathXmlApplicationContext(
        "org/springframework/context/annotation/matchingResourcePatternTests.xml");
    assertTrue(context.containsBean("fooServiceImpl"));
  }

  public void testComponentScanWithAutowiredQualifier() {
    ApplicationContext context = new ClassPathXmlApplicationContext(
        "org/springframework/context/annotation/componentScanWithAutowiredQualifierTests.xml");
View Full Code Here

        if (AESUtil.class.getResource("/" + configLocation) == null) {
            throw new SkipException(configLocation + " is not inaccessible or doesn't exist on the path.");
        }
       
        ApplicationContext context = new ClassPathXmlApplicationContext(configLocation);
        assertTrue(context.containsBean("oauthConnectionInfo"),
                    "Could not find oauthConnectionInfo bean after parsing " + configLocation);
        assertTrue(context.containsBean("oauthConnector"),
                    "Could not find oauthConnector bean after parsing " + configLocation);
        assertTrue(context.containsBean("forceRememberMeServices"),
                    "Could not find forceRememberMeServices bean after parsing " + configLocation);
View Full Code Here

        }
       
        ApplicationContext context = new ClassPathXmlApplicationContext(configLocation);
        assertTrue(context.containsBean("oauthConnectionInfo"),
                    "Could not find oauthConnectionInfo bean after parsing " + configLocation);
        assertTrue(context.containsBean("oauthConnector"),
                    "Could not find oauthConnector bean after parsing " + configLocation);
        assertTrue(context.containsBean("forceRememberMeServices"),
                    "Could not find forceRememberMeServices bean after parsing " + configLocation);
        assertTrue(context.containsBean("rememberMeFilter"),
                    "Could not find rememberMeFilter bean after parsing " + configLocation);
View Full Code Here

        ApplicationContext context = new ClassPathXmlApplicationContext(configLocation);
        assertTrue(context.containsBean("oauthConnectionInfo"),
                    "Could not find oauthConnectionInfo bean after parsing " + configLocation);
        assertTrue(context.containsBean("oauthConnector"),
                    "Could not find oauthConnector bean after parsing " + configLocation);
        assertTrue(context.containsBean("forceRememberMeServices"),
                    "Could not find forceRememberMeServices bean after parsing " + configLocation);
        assertTrue(context.containsBean("rememberMeFilter"),
                    "Could not find rememberMeFilter bean after parsing " + configLocation);
        assertTrue(context.containsBean("connectionStorageFilter"),
                    "Could not find connectionStorageFilter bean after parsing " + configLocation);
View Full Code Here

                    "Could not find oauthConnectionInfo bean after parsing " + configLocation);
        assertTrue(context.containsBean("oauthConnector"),
                    "Could not find oauthConnector bean after parsing " + configLocation);
        assertTrue(context.containsBean("forceRememberMeServices"),
                    "Could not find forceRememberMeServices bean after parsing " + configLocation);
        assertTrue(context.containsBean("rememberMeFilter"),
                    "Could not find rememberMeFilter bean after parsing " + configLocation);
        assertTrue(context.containsBean("connectionStorageFilter"),
                    "Could not find connectionStorageFilter bean after parsing " + configLocation);
       
        ForceOAuthConnectionInfo connInfo = context.getBean("oauthConnectionInfo", ForceOAuthConnectionInfo.class);
View Full Code Here

                    "Could not find oauthConnector bean after parsing " + configLocation);
        assertTrue(context.containsBean("forceRememberMeServices"),
                    "Could not find forceRememberMeServices bean after parsing " + configLocation);
        assertTrue(context.containsBean("rememberMeFilter"),
                    "Could not find rememberMeFilter bean after parsing " + configLocation);
        assertTrue(context.containsBean("connectionStorageFilter"),
                    "Could not find connectionStorageFilter bean after parsing " + configLocation);
       
        ForceOAuthConnectionInfo connInfo = context.getBean("oauthConnectionInfo", ForceOAuthConnectionInfo.class);
        ForceOAuthConnector connector = context.getBean("oauthConnector", ForceOAuthConnector.class);
       
View Full Code Here

        verifyConnectionUrlMethod(configLocation);
    }

    private void verifyConnectionUrlMethod(String configLocation) {
        ApplicationContext context = new ClassPathXmlApplicationContext(configLocation);
        assertTrue(context.containsBean("oauthConnectionInfo"),
                    "Could not find oauthConnectionInfo bean after parsing " + configLocation);
        assertTrue(context.containsBean("oauthConnector"),
                    "Could not find oauthConnector bean after parsing " + configLocation);
        assertTrue(context.containsBean("forceRememberMeServices"),
                    "Could not find forceRememberMeServices bean after parsing " + configLocation);
View Full Code Here

    private void verifyConnectionUrlMethod(String configLocation) {
        ApplicationContext context = new ClassPathXmlApplicationContext(configLocation);
        assertTrue(context.containsBean("oauthConnectionInfo"),
                    "Could not find oauthConnectionInfo bean after parsing " + configLocation);
        assertTrue(context.containsBean("oauthConnector"),
                    "Could not find oauthConnector bean after parsing " + configLocation);
        assertTrue(context.containsBean("forceRememberMeServices"),
                    "Could not find forceRememberMeServices bean after parsing " + configLocation);
        assertTrue(context.containsBean("rememberMeFilter"),
                    "Could not find rememberMeFilter bean after parsing " + configLocation);
View Full Code Here

        ApplicationContext context = new ClassPathXmlApplicationContext(configLocation);
        assertTrue(context.containsBean("oauthConnectionInfo"),
                    "Could not find oauthConnectionInfo bean after parsing " + configLocation);
        assertTrue(context.containsBean("oauthConnector"),
                    "Could not find oauthConnector bean after parsing " + configLocation);
        assertTrue(context.containsBean("forceRememberMeServices"),
                    "Could not find forceRememberMeServices bean after parsing " + configLocation);
        assertTrue(context.containsBean("rememberMeFilter"),
                    "Could not find rememberMeFilter bean after parsing " + configLocation);
        assertTrue(context.containsBean("connectionStorageFilter"),
                    "Could not find connectionStorageFilter bean after parsing " + configLocation);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.