Package org.springframework.core.env

Examples of org.springframework.core.env.Environment.acceptsProfiles()


    @Test
    public void noProfileSpecified() {
        // activateProfiles(...);
        Environment env = runApp().getEnvironment();
        assertThat(env.acceptsProfiles(env.getDefaultProfiles()), is(true));
        assertThat(env.acceptsProfiles(CLOUDFOUNDRY), is(false));
        assertThat(env.acceptsProfiles(STANDALONE), is(true));
    }

    @After
View Full Code Here


    @Test
    public void noProfileSpecified() {
        // activateProfiles(...);
        Environment env = runApp().getEnvironment();
        assertThat(env.acceptsProfiles(env.getDefaultProfiles()), is(true));
        assertThat(env.acceptsProfiles(CLOUDFOUNDRY), is(false));
        assertThat(env.acceptsProfiles(STANDALONE), is(true));
    }

    @After
    public void clearProperty() {
View Full Code Here

    public void noProfileSpecified() {
        // activateProfiles(...);
        Environment env = runApp().getEnvironment();
        assertThat(env.acceptsProfiles(env.getDefaultProfiles()), is(true));
        assertThat(env.acceptsProfiles(CLOUDFOUNDRY), is(false));
        assertThat(env.acceptsProfiles(STANDALONE), is(true));
    }

    @After
    public void clearProperty() {
        System.clearProperty(ACTIVE_PROFILES_PROPERTY_NAME);
View Full Code Here

        springSecurityFilter.setAsyncSupported(true);

        initAtmosphereServlet(servletContext);

        Environment env = rootContext.getBean(Environment.class);
        if (env.acceptsProfiles(Constants.SPRING_PROFILE_METRICS)) {
            initMetricsServlet(servletContext, disps, dispatcherServlet);
            springSecurityFilter.addMappingForServletNames(disps, true, "dispatcher", "atmosphereServlet", "metricsAdminServlet");
        } else {
            springSecurityFilter.addMappingForServletNames(disps, true, "dispatcher", "atmosphereServlet");
        }
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.