Package org.springframework.ide.eclipse.beans.core.internal.model

Examples of org.springframework.ide.eclipse.beans.core.internal.model.BeansConfig


  // assertTrue(hyperlinks.size() == 1);
  // }

  @Test
  public void testMultipleBeansAutowireHyperlink() throws Exception {
    BeansConfig config = new BeansConfig(beansProject,
        "src/org/springframework/beans/factory/annotation/2-beans-context.xml", IBeansConfig.Type.MANUAL);

    AutowireHyperlinkDetector detector = new AutowireHyperlinkDetector();
    Set<AutowireBeanHyperlink> hyperlinks = new HashSet<AutowireBeanHyperlink>();
    detector.addHyperlinksHelper(config, "test.beans.TestBean", project, hyperlinks);
View Full Code Here


    assertTrue(hyperlinks.size() == 2);
  }

  @Test
  public void testPrimitiveType() throws Exception {
    BeansConfig config = new BeansConfig(beansProject,
        "src/org/springframework/beans/factory/annotation/1-bean-context.xml", IBeansConfig.Type.MANUAL);

    AutowireHyperlinkDetector detector = new AutowireHyperlinkDetector();
    Set<AutowireBeanHyperlink> hyperlinks = new HashSet<AutowireBeanHyperlink>();
    detector.addHyperlinksHelper(config, "int", project, hyperlinks);
View Full Code Here

    project.delete(true, null);
  }

  @Test
  public void testBasicConfigBeans() throws Exception {
    BeansConfig config = new BeansConfig(beansProject, "basic-bean-config.xml", IBeansConfig.Type.MANUAL);
   
    Set<IBean> beans = BeansModelUtils.getBeans(config);
    assertEquals(1, beans.size());

    IBean bean = beans.iterator().next();
    assertEquals("simpleBean", bean.getElementName());
   
    IModelElement[] children = config.getElementChildren();
    assertEquals(1, children.length);
  }
View Full Code Here

    assertEquals(1, children.length);
  }

  @Test
  public void testAdvancedConfigBeans() throws Exception {
    BeansConfig config = new BeansConfig(beansProject, "advanced-bean-config.xml", IBeansConfig.Type.MANUAL);
   
    Set<IBean> beans = BeansModelUtils.getBeans(config);
    assertEquals(2, beans.size());

    assertNotNull(BeansModelUtils.getBean("simpleBean", config));
View Full Code Here

    assertEquals("org.springframework.aop.aspectj.annotation.AnnotationAwareAspectJAutoProxyCreator", aspectjBean.getClassName());
  }

  @Test
  public void testBasicComponentScanning() throws Exception {
    BeansConfig config = new BeansConfig(beansProject, "basic-component-scanning.xml", IBeansConfig.Type.MANUAL);
   
    IBean bean = BeansModelUtils.getBean("simpleScannedBean", config);
    assertEquals("simpleScannedBean", bean.getElementName());
  }
View Full Code Here

    assertEquals("simpleScannedBean", bean.getElementName());
  }

  @Test
  public void testComponentScanningWithEnableAnnotations() throws Exception {
    BeansConfig config = new BeansConfig(beansProject, "advanced-component-scanning.xml", IBeansConfig.Type.MANUAL);
   
    IBean simpleBean = BeansModelUtils.getBean("simpleScannedBean", config);
    assertEquals("simpleScannedBean", simpleBean.getElementName());

    IBean bean = BeansModelUtils.getBean("advancedConfigurationClass", config);
View Full Code Here

    assertEquals("org.springframework.aop.aspectj.annotation.AnnotationAwareAspectJAutoProxyCreator", aspectjBean.getClassName());
  }

  @Test
  public void testComponentScanningWithProfile() throws Exception {
    BeansConfig config = new BeansConfig(beansProject, "profile-component-scanning.xml", IBeansConfig.Type.MANUAL);
   
    IBean simpleBean = BeansModelUtils.getBean("simpleScannedBean", config);
    assertEquals("simpleScannedBean", simpleBean.getElementName());

    IBean configClassBean = BeansModelUtils.getBean("profileConfigurationClass", config);
View Full Code Here

TOP

Related Classes of org.springframework.ide.eclipse.beans.core.internal.model.BeansConfig

Copyright © 2018 www.massapicom. 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.