use of com.dailystudio.dataobject.samples.TestDatabaseObject in project devbricks by dailystudio.
the class DatabaseObjectFactoryTest method testCreateDefaultDatabaseObject.
public void testCreateDefaultDatabaseObject() {
DatabaseObjectFactory factory = DatabaseObjectFactory.getInstance();
assertNotNull(factory);
DatabaseObject object1 = null;
DatabaseObject object2 = null;
object1 = factory.createObject(new DatabaseObjectCreationParams(null));
assertNotNull(object1);
assertEquals(true, object1 instanceof DatabaseObject);
object2 = factory.createObject(new DatabaseObjectCreationParams(TestDatabaseObject.class));
assertNotNull(object2);
assertEquals(false, (object1 == object2));
assertEquals(true, object2 instanceof TestDatabaseObject);
}
Aggregations