Search in sources :

Example 1 with IntegerType

use of org.jboss.tools.hibernate.runtime.v_6_0.internal.legacy.IntegerType in project jbosstools-hibernate by jbosstools.

the class TypeFacadeTest method testGetPrimitiveClass.

// TODO JBIDE-28154: Investigate failure
@Disabled
@Test
public void testGetPrimitiveClass() {
    IType typeFacade = null;
    ClassType classType = new ClassType();
    typeFacade = new TypeFacadeImpl(FACADE_FACTORY, classType) {
    };
    assertNull(typeFacade.getPrimitiveClass());
    IntegerType integerType = new IntegerType();
    typeFacade = new TypeFacadeImpl(FACADE_FACTORY, integerType) {
    };
    assertEquals(int.class, typeFacade.getPrimitiveClass());
}
Also used : IntegerType(org.jboss.tools.hibernate.runtime.v_6_0.internal.legacy.IntegerType) ClassType(org.jboss.tools.hibernate.runtime.v_6_0.internal.legacy.ClassType) IType(org.jboss.tools.hibernate.runtime.spi.IType) Test(org.junit.jupiter.api.Test) Disabled(org.junit.jupiter.api.Disabled)

Example 2 with IntegerType

use of org.jboss.tools.hibernate.runtime.v_6_0.internal.legacy.IntegerType in project jbosstools-hibernate by jbosstools.

the class TypeFacadeTest method testIsInstanceOfPrimitiveType.

// TODO JBIDE-28154: Investigate failure
@Disabled
@Test
public void testIsInstanceOfPrimitiveType() {
    IType typeFacade = null;
    ClassType classType = new ClassType();
    typeFacade = new TypeFacadeImpl(FACADE_FACTORY, classType) {
    };
    assertFalse(typeFacade.isInstanceOfPrimitiveType());
    StringType stringType = new StringType();
    typeFacade = new TypeFacadeImpl(FACADE_FACTORY, stringType) {
    };
    assertFalse(typeFacade.isInstanceOfPrimitiveType());
    IntegerType integerType = new IntegerType();
    typeFacade = new TypeFacadeImpl(FACADE_FACTORY, integerType) {
    };
    assertTrue(typeFacade.isInstanceOfPrimitiveType());
}
Also used : IntegerType(org.jboss.tools.hibernate.runtime.v_6_0.internal.legacy.IntegerType) StringType(org.jboss.tools.hibernate.runtime.v_6_0.internal.legacy.StringType) ClassType(org.jboss.tools.hibernate.runtime.v_6_0.internal.legacy.ClassType) IType(org.jboss.tools.hibernate.runtime.spi.IType) Test(org.junit.jupiter.api.Test) Disabled(org.junit.jupiter.api.Disabled)

Example 3 with IntegerType

use of org.jboss.tools.hibernate.runtime.v_6_0.internal.legacy.IntegerType in project jbosstools-hibernate by jbosstools.

the class TypeFacadeTest method testIsIntegerType.

@Test
public void testIsIntegerType() {
    IType typeFacade = null;
    ClassType classType = new ClassType();
    typeFacade = new TypeFacadeImpl(FACADE_FACTORY, classType) {
    };
    assertFalse(typeFacade.isIntegerType());
    IntegerType integerType = new IntegerType();
    typeFacade = new TypeFacadeImpl(FACADE_FACTORY, integerType) {
    };
    assertTrue(typeFacade.isIntegerType());
}
Also used : IntegerType(org.jboss.tools.hibernate.runtime.v_6_0.internal.legacy.IntegerType) ClassType(org.jboss.tools.hibernate.runtime.v_6_0.internal.legacy.ClassType) IType(org.jboss.tools.hibernate.runtime.spi.IType) Test(org.junit.jupiter.api.Test)

Aggregations

IType (org.jboss.tools.hibernate.runtime.spi.IType)3 ClassType (org.jboss.tools.hibernate.runtime.v_6_0.internal.legacy.ClassType)3 IntegerType (org.jboss.tools.hibernate.runtime.v_6_0.internal.legacy.IntegerType)3 Test (org.junit.jupiter.api.Test)3 Disabled (org.junit.jupiter.api.Disabled)2 StringType (org.jboss.tools.hibernate.runtime.v_6_0.internal.legacy.StringType)1