use of uk.gov.gchq.gaffer.graph.hook.Log4jLogger in project Gaffer by gchq.
the class AddGraphWithHooksTest method shouldShallowCloneOperation.
@Test
@Override
public void shouldShallowCloneOperation() {
final AddGraphWithHooks a = new Builder().graphId("graphId").parentPropertiesId("testPropID").parentSchemaIds(Lists.newArrayList("testSchemaID")).schema(new Schema.Builder().build()).graphAuths("testAuth").storeProperties(new StoreProperties()).hooks(new Log4jLogger()).disabledByDefault(true).readAccessPredicate(READ_ACCESS_PREDICATE).writeAccessPredicate(WRITE_ACCESS_PREDICATE).build();
final AddGraphWithHooks b = a.shallowClone();
assertEquals(a.getGraphId(), b.getGraphId());
assertEquals(a.getStoreProperties(), b.getStoreProperties());
assertEquals(a.getSchema(), b.getSchema());
assertEquals(a.getGraphAuths(), b.getGraphAuths());
assertArrayEquals(a.getHooks(), b.getHooks());
assertTrue(b.isDisabledByDefault());
assertEquals(a.getReadAccessPredicate(), b.getReadAccessPredicate());
assertEquals(a.getWriteAccessPredicate(), b.getWriteAccessPredicate());
}
Aggregations