Examples of Mockery


Examples of org.jmock.Mockery

   
    new EntityBeanConverter(jdtFacade).addTableAnnotation(entityBean, entity);
  }
 
  public void testShouldAddTableAnnotation() throws Exception {
    Mockery context = new Mockery();
    final IJDTFacade jdtFacade = context.mock(IJDTFacade.class);

        AppModule appModule = new TestFixture().getAppModule("basicentity-ejb-jar.xml", "basicentity-openejb-jar.xml");
    Entity entity = appModule.getCmpMappings().getEntityMap().get("openejb.java.lang.Product");
    EntityBean entityBean = (EntityBean) appModule.getEjbModules().get(0).getEjbJar().getEnterpriseBean("ProductEJB");
   
    context.checking(new Expectations() {
      {
        Map<String,Object> properties = new HashMap<String, Object>();
        properties.put("name", "products");
        one(jdtFacade).addClassAnnotation("org.superbiz.ProductBean", Table.class, properties);
      }
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.