Search in sources :

Example 6 with ICfg2HbmTool

use of org.jboss.tools.hibernate.runtime.spi.ICfg2HbmTool in project jbosstools-hibernate by jbosstools.

the class FacadeFactoryTest method testCreateCfg2HbmTool.

@Test
public void testCreateCfg2HbmTool() {
    Cfg2HbmTool cfg2HbmTool = new Cfg2HbmTool();
    ICfg2HbmTool facade = facadeFactory.createCfg2HbmTool(cfg2HbmTool);
    Assert.assertSame(cfg2HbmTool, ((IFacade) facade).getTarget());
}
Also used : ICfg2HbmTool(org.jboss.tools.hibernate.runtime.spi.ICfg2HbmTool) Cfg2HbmTool(org.hibernate.tool.hbm2x.Cfg2HbmTool) ICfg2HbmTool(org.jboss.tools.hibernate.runtime.spi.ICfg2HbmTool) Test(org.junit.Test)

Example 7 with ICfg2HbmTool

use of org.jboss.tools.hibernate.runtime.spi.ICfg2HbmTool in project jbosstools-hibernate by jbosstools.

the class ServiceImplTest method testNewCfg2HbmTool.

@Test
public void testNewCfg2HbmTool() {
    ICfg2HbmTool cfg2HbmTool = service.newCfg2HbmTool();
    Assert.assertNotNull(cfg2HbmTool);
    Object target = ((IFacade) cfg2HbmTool).getTarget();
    Assert.assertNotNull(target);
    Assert.assertTrue(target instanceof Cfg2HbmTool);
}
Also used : ICfg2HbmTool(org.jboss.tools.hibernate.runtime.spi.ICfg2HbmTool) Cfg2HbmTool(org.hibernate.tool.hbm2x.Cfg2HbmTool) ICfg2HbmTool(org.jboss.tools.hibernate.runtime.spi.ICfg2HbmTool) IFacade(org.jboss.tools.hibernate.runtime.common.IFacade) Test(org.junit.Test)

Example 8 with ICfg2HbmTool

use of org.jboss.tools.hibernate.runtime.spi.ICfg2HbmTool in project jbosstools-hibernate by jbosstools.

the class FacadeFactoryTest method testCreateCfg2HbmTool.

@Test
public void testCreateCfg2HbmTool() {
    Cfg2HbmTool cfg2HbmTool = new Cfg2HbmTool();
    ICfg2HbmTool facade = facadeFactory.createCfg2HbmTool(cfg2HbmTool);
    Assert.assertSame(cfg2HbmTool, ((IFacade) facade).getTarget());
}
Also used : ICfg2HbmTool(org.jboss.tools.hibernate.runtime.spi.ICfg2HbmTool) Cfg2HbmTool(org.hibernate.tool.hbm2x.Cfg2HbmTool) ICfg2HbmTool(org.jboss.tools.hibernate.runtime.spi.ICfg2HbmTool) Test(org.junit.Test)

Example 9 with ICfg2HbmTool

use of org.jboss.tools.hibernate.runtime.spi.ICfg2HbmTool in project jbosstools-hibernate by jbosstools.

the class FacadeFactoryTest method testCreateCfg2HbmTool.

@Test
public void testCreateCfg2HbmTool() {
    Cfg2HbmTool cfg2HbmTool = new Cfg2HbmTool();
    ICfg2HbmTool facade = facadeFactory.createCfg2HbmTool(cfg2HbmTool);
    Assert.assertSame(cfg2HbmTool, ((IFacade) facade).getTarget());
}
Also used : ICfg2HbmTool(org.jboss.tools.hibernate.runtime.spi.ICfg2HbmTool) Cfg2HbmTool(org.hibernate.tool.hbm2x.Cfg2HbmTool) ICfg2HbmTool(org.jboss.tools.hibernate.runtime.spi.ICfg2HbmTool) Test(org.junit.Test)

Example 10 with ICfg2HbmTool

use of org.jboss.tools.hibernate.runtime.spi.ICfg2HbmTool in project jbosstools-hibernate by jbosstools.

the class ServiceImplTest method testNewCfg2HbmTool.

@Test
public void testNewCfg2HbmTool() {
    ICfg2HbmTool cfg2HbmTool = service.newCfg2HbmTool();
    Assert.assertNotNull(cfg2HbmTool);
    Object target = ((IFacade) cfg2HbmTool).getTarget();
    Assert.assertNotNull(target);
    Assert.assertTrue(target instanceof Cfg2HbmTool);
}
Also used : ICfg2HbmTool(org.jboss.tools.hibernate.runtime.spi.ICfg2HbmTool) Cfg2HbmTool(org.hibernate.tool.hbm2x.Cfg2HbmTool) ICfg2HbmTool(org.jboss.tools.hibernate.runtime.spi.ICfg2HbmTool) IFacade(org.jboss.tools.hibernate.runtime.common.IFacade) Test(org.junit.Test)

Aggregations

ICfg2HbmTool (org.jboss.tools.hibernate.runtime.spi.ICfg2HbmTool)15 Cfg2HbmTool (org.hibernate.tool.hbm2x.Cfg2HbmTool)12 Test (org.junit.Test)12 IFacade (org.jboss.tools.hibernate.runtime.common.IFacade)4 IPersistentClass (org.jboss.tools.hibernate.runtime.spi.IPersistentClass)2 ArrayList (java.util.ArrayList)1 BadLocationException (org.eclipse.jface.text.BadLocationException)1 IRegion (org.eclipse.jface.text.IRegion)1 Region (org.eclipse.jface.text.Region)1