use of io.crnk.meta.model.MetaAttribute in project crnk-framework by crnk-project.
the class JpaMetaEndToEndTest method testProjectedLob.
@Test
public void testProjectedLob() {
MetaResource metaResource = resourceMetaProvider.getMeta(AnnotationTestEntity.class);
MetaAttribute lobAttr = metaResource.getAttribute("lobValue");
Assert.assertTrue(lobAttr.isLob());
}
use of io.crnk.meta.model.MetaAttribute in project crnk-framework by crnk-project.
the class JpaMetaEndToEndTest method testProjectedColumnAnnotatedValueIsNotNullable.
@Test
public void testProjectedColumnAnnotatedValueIsNotNullable() {
MetaResourceBase meta = resourceMetaProvider.getMeta(AnnotationTestEntity.class);
MetaAttribute field = meta.getAttribute("notNullableValue");
Assert.assertFalse(field.isNullable());
}
use of io.crnk.meta.model.MetaAttribute in project crnk-framework by crnk-project.
the class JpaMetaEndToEndTest method testCascaded.
@Test
public void testCascaded() {
MetaResource meta = resourceMetaProvider.getMeta(TestEntity.class);
MetaAttribute oneRelatedAttr = meta.getAttribute("oneRelatedValue");
MetaAttribute eagerRelatedAttr = meta.getAttribute("eagerRelatedValue");
Assert.assertTrue(oneRelatedAttr.isCascaded());
Assert.assertFalse(eagerRelatedAttr.isCascaded());
}
use of io.crnk.meta.model.MetaAttribute in project crnk-framework by crnk-project.
the class JpaNullabilityMetaTest method testNonOptionalRelatedValue.
@Test
public void testNonOptionalRelatedValue() {
MetaEntity meta = metaProvider.discoverMeta(AnnotationTestEntity.class);
MetaAttribute field = meta.getAttribute("nonOptionalRelatedValue");
Assert.assertFalse(field.isNullable());
}
use of io.crnk.meta.model.MetaAttribute in project crnk-framework by crnk-project.
the class JpaNullabilityMetaTest method testPrimitiveValueNotNullable.
@Test
public void testPrimitiveValueNotNullable() {
MetaEntity meta = metaProvider.discoverMeta(TestEntity.class);
MetaAttribute field = meta.getAttribute("longValue");
Assert.assertFalse(field.isNullable());
}
Aggregations