Examples of ApplicationContext


Examples of org.springframework.context.ApplicationContext

public class AutoConfigProcessorTest {

  public void testGet() {
    StopWatch watch = new StopWatch();
    watch.start();
    ApplicationContext factory = new ClassPathXmlApplicationContext("/context-auto.xml");
    testBean(factory);
    testFactoryBean(factory);
    System.out.println("config  context-auto completed using " + watch.getTime());
  }
View Full Code Here

Examples of org.springframework.context.ApplicationContext

  }

  public void testNoAutowire() {
    StopWatch watch = new StopWatch();
    watch.start();
    ApplicationContext factory = new ClassPathXmlApplicationContext("/context-auto.xml");
    String name = SomeAction.class.getName();
    for (int i = 0; i < 100; i++) {
      factory.getBean(name);
    }
    System.out.println("no autowire using " + watch.getTime());
  }
View Full Code Here

Examples of org.springframework.context.ApplicationContext

    System.setProperty("rp.root","red-adaptive-search/tmp");
   
    File myFile = new File(".");
    log.debug(myFile.getAbsolutePath());
   
    ApplicationContext context = new FileSystemXmlApplicationContext(
        "red-adaptive-search/war/WEB-INF/simple/appContext.xml");

    // get the knowledgemanager
    knowledgeManager = (KnowledgeSphereManager) context
        .getBean(Config.KNOWLEDGEMANAGER_PLUGINNAME);

  }
View Full Code Here

Examples of org.springframework.context.ApplicationContext

        new DependencyCheckPostProcessor.Version("1.2.3")));
  }

  @Test
  public void testNormalGood() throws Exception {
    ApplicationContext ac = loadApplicationContext("/org/geomajas/spring/dependencyTestNormalGood.xml");
    TestRecorder recorder = ac.getBean(TestRecorder.class);
    Assert.assertEquals("", recorder.matches(DependencyCheckPostProcessor.GROUP,
        DependencyCheckPostProcessor.VALUE));
  }
View Full Code Here

Examples of org.springframework.context.ApplicationContext

    }
  }

  @Test
  public void testChecksInIdeBD() throws Exception {
    ApplicationContext ac = loadApplicationContext("/org/geomajas/spring/dependencyTestInIdeBackendDef.xml");
    TestRecorder recorder = ac.getBean(TestRecorder.class);
    Assert.assertEquals("", recorder.matches(DependencyCheckPostProcessor.GROUP,
        DependencyCheckPostProcessor.VALUE));
  }
View Full Code Here

Examples of org.springframework.context.ApplicationContext

        DependencyCheckPostProcessor.VALUE));
  }

  @Test
  public void testChecksInIdeBR() throws Exception {
    ApplicationContext ac = loadApplicationContext("/org/geomajas/spring/dependencyTestInIdeBackendRef.xml");
    TestRecorder recorder = ac.getBean(TestRecorder.class);
    Assert.assertEquals("", recorder.matches(DependencyCheckPostProcessor.GROUP,
        DependencyCheckPostProcessor.VALUE));
  }
View Full Code Here

Examples of org.springframework.context.ApplicationContext

        DependencyCheckPostProcessor.VALUE));
  }

  @Test
  public void testChecksInIdePD() throws Exception {
    ApplicationContext ac = loadApplicationContext("/org/geomajas/spring/dependencyTestInIdePluginDef.xml");
    TestRecorder recorder = ac.getBean(TestRecorder.class);
    Assert.assertEquals("", recorder.matches(DependencyCheckPostProcessor.GROUP,
        DependencyCheckPostProcessor.VALUE));
  }
View Full Code Here

Examples of org.springframework.context.ApplicationContext

        DependencyCheckPostProcessor.VALUE));
  }

  @Test
  public void testChecksInIdePR() throws Exception {
    ApplicationContext ac = loadApplicationContext("/org/geomajas/spring/dependencyTestInIdePluginRef.xml");
    TestRecorder recorder = ac.getBean(TestRecorder.class);
    Assert.assertEquals("", recorder.matches(DependencyCheckPostProcessor.GROUP,
        DependencyCheckPostProcessor.VALUE));
  }
View Full Code Here

Examples of org.springframework.context.ApplicationContext

        DependencyCheckPostProcessor.VALUE));
  }

  @Test
  public void testChecksDuplicatePluginGood() throws Exception {
    ApplicationContext ac = loadApplicationContext("/org/geomajas/spring/dependencyTestDuplicatePluginGood.xml");
    TestRecorder recorder = ac.getBean(TestRecorder.class);
    Assert.assertEquals("", recorder.matches(DependencyCheckPostProcessor.GROUP,
        DependencyCheckPostProcessor.VALUE));
  }
View Full Code Here

Examples of org.springframework.context.ApplicationContext

    }
  }

  @Test
  public void testChecksOptionalGood() throws Exception {
    ApplicationContext ac = loadApplicationContext("/org/geomajas/spring/dependencyTestOptionalGood.xml");
    TestRecorder recorder = ac.getBean(TestRecorder.class);
    Assert.assertEquals("", recorder.matches(DependencyCheckPostProcessor.GROUP,
        DependencyCheckPostProcessor.VALUE));
  }
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.