Package org.springframework.context

Examples of org.springframework.context.ApplicationContext.containsBean()


                    "Should 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);
        UserDataRetrievalService userDataRetrievalService =
            context.getBean("userDataRetrievalService", UserDataRetrievalService.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);
        UserDataRetrievalService userDataRetrievalService =
            context.getBean("userDataRetrievalService", UserDataRetrievalService.class);
       
        Assert.assertFalse(userDataRetrievalService.isStoreUsername(),
View Full Code Here

   
    @Test
    public void testParseConnectionNameWithCustomRetriever() {
        String configLocation = "security-config-ns-connNameAndCustomRetriever.xml";
        ApplicationContext context = new ClassPathXmlApplicationContext(configLocation);
        assertFalse(context.containsBean("oauthConnectionInfo"),
                    "Should not find oauthConnectionInfo bean after parsing " + configLocation);
        assertTrue(context.containsBean("oauthConnector"),
                    "Could not find oauthConnector bean after parsing " + configLocation);
        assertTrue(context.containsBean("userDataRetrievalService"),
                    "Could not find customUserDataRetrieverService bean after parsing " + configLocation);
View Full Code Here

    public void testParseConnectionNameWithCustomRetriever() {
        String configLocation = "security-config-ns-connNameAndCustomRetriever.xml";
        ApplicationContext context = new ClassPathXmlApplicationContext(configLocation);
        assertFalse(context.containsBean("oauthConnectionInfo"),
                    "Should not find oauthConnectionInfo bean after parsing " + configLocation);
        assertTrue(context.containsBean("oauthConnector"),
                    "Could not find oauthConnector bean after parsing " + configLocation);
        assertTrue(context.containsBean("userDataRetrievalService"),
                    "Could not find customUserDataRetrieverService bean after parsing " + configLocation);
        assertTrue(context.containsBean("testUserDataRetriever"),
                    "Could not find testUserDataRetriever bean after parsing " + configLocation);
View Full Code Here

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

                    "Should not find oauthConnectionInfo bean after parsing " + configLocation);
        assertTrue(context.containsBean("oauthConnector"),
                    "Could not find oauthConnector bean after parsing " + configLocation);
        assertTrue(context.containsBean("userDataRetrievalService"),
                    "Could not find customUserDataRetrieverService bean after parsing " + configLocation);
        assertTrue(context.containsBean("testUserDataRetriever"),
                    "Could not find testUserDataRetriever 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

                    "Could not find oauthConnector bean after parsing " + configLocation);
        assertTrue(context.containsBean("userDataRetrievalService"),
                    "Could not find customUserDataRetrieverService bean after parsing " + configLocation);
        assertTrue(context.containsBean("testUserDataRetriever"),
                    "Could not find testUserDataRetriever 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 customUserDataRetrieverService bean after parsing " + configLocation);
        assertTrue(context.containsBean("testUserDataRetriever"),
                    "Could not find testUserDataRetriever 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);
       
        ForceOAuthConnector connector = context.getBean("oauthConnector", ForceOAuthConnector.class);
View Full Code Here

                    "Could not find testUserDataRetriever 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);
       
        ForceOAuthConnector connector = context.getBean("oauthConnector", ForceOAuthConnector.class);
       
        ForceConnectionStorageFilter connStorageFilter = context.getBean(ForceConnectionStorageFilter.class);
View Full Code Here

             } catch (BeansException be) {
                 throw new RuntimeException("Unable to load Tatool file.", be);
             }
            
             // see whether we have exporters
             if (moduleContext.containsBean("moduleExporters")) {
               Map<String, DataExporter> exporters = (Map<String, DataExporter>) moduleContext.getBean("moduleExporters");
                 return exporters;
             } else {
                 return Collections.emptyMap();
             }
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.