use of com.pushtorefresh.storio3.sqlite.annotations.processor.StorIOSQLiteProcessor in project storio by pushtorefresh.
the class StorIOSQLiteAnnotationsProcessorTest method shouldNotCompileIfClassDoesNotHaveKey.
@Test
public void shouldNotCompileIfClassDoesNotHaveKey() {
JavaFileObject model = JavaFileObjects.forResource("NoKey.java");
assert_().about(javaSource()).that(model).processedWith(new StorIOSQLiteProcessor()).failsToCompile().withErrorContaining("Class marked with StorIOSQLiteType annotation should have at least one KEY field or method marked with" + " StorIOSQLiteColumn annotation: NoKey");
}
use of com.pushtorefresh.storio3.sqlite.annotations.processor.StorIOSQLiteProcessor in project storio by pushtorefresh.
the class StorIOSQLiteAnnotationsProcessorTest method shouldNotCompileIfIgnoreNullIsUsedOnPrimitive.
@Test
public void shouldNotCompileIfIgnoreNullIsUsedOnPrimitive() {
JavaFileObject model = JavaFileObjects.forResource("IgnoreNullOnPrimitive.java");
assert_().about(javaSource()).that(model).processedWith(new StorIOSQLiteProcessor()).failsToCompile().withErrorContaining("ignoreNull should not be used for primitive type: id");
}
use of com.pushtorefresh.storio3.sqlite.annotations.processor.StorIOSQLiteProcessor in project storio by pushtorefresh.
the class StorIOSQLiteAnnotationsProcessorTest method shouldNotCompileIfClassIsEmpty.
@Test
public void shouldNotCompileIfClassIsEmpty() {
JavaFileObject model = JavaFileObjects.forResource("EmptyClass.java");
assert_().about(javaSource()).that(model).processedWith(new StorIOSQLiteProcessor()).failsToCompile().withErrorContaining("Class marked with StorIOSQLiteType annotation should have at least one field or method marked with" + " StorIOSQLiteColumn annotation: EmptyClass");
}
use of com.pushtorefresh.storio3.sqlite.annotations.processor.StorIOSQLiteProcessor in project storio by pushtorefresh.
the class StorIOSQLiteAnnotationsProcessorTest method shouldCompileIfAnnotatedFieldIsPrivateAndHasIsGetter.
@Test
public void shouldCompileIfAnnotatedFieldIsPrivateAndHasIsGetter() {
JavaFileObject model = JavaFileObjects.forResource("PrivateFieldWithIsGetter.java");
assert_().about(javaSource()).that(model).processedWith(new StorIOSQLiteProcessor()).compilesWithoutError();
}
use of com.pushtorefresh.storio3.sqlite.annotations.processor.StorIOSQLiteProcessor in project storio by pushtorefresh.
the class StorIOSQLiteAnnotationsProcessorTest method shouldCompileIfAnnotatedFieldIsPrivateAndHasNameStartingWithIs.
@Test
public void shouldCompileIfAnnotatedFieldIsPrivateAndHasNameStartingWithIs() {
JavaFileObject model = JavaFileObjects.forResource("PrivateFieldWithNameStartingWithIs.java");
assert_().about(javaSource()).that(model).processedWith(new StorIOSQLiteProcessor()).compilesWithoutError();
}
Aggregations