FederatedOperationChainValidator extends OperationChainValidator { @Override protected Schema getSchema(final Operation operation, final User user, final Store store) { return ((FederatedStore) store).getSchema(operation, user); } FederatedOperationChainValidator(final ViewValidator viewValidator);   }
@Test public void shouldGetFederatedSchema() { final ViewValidator viewValidator = mock(FederatedViewValidator.class); final FederatedOperationChainValidator validator = new FederatedOperationChainValidator(viewValidator); final FederatedStore store = mock(FederatedStore.class); final User user = mock(User.class); final Operation op = mock(Operation.class); final Schema schema = mock(Schema.class); given(store.getSchema(op, user)).willReturn(schema); final Schema actualSchema = validator.getSchema(op, user, store); assertSame(schema, actualSchema); }