Search in sources :

Example 1 with UserFactory

use of uk.gov.gchq.gaffer.rest.factory.UserFactory in project Gaffer by gchq.

the class OperationControllerTest method setUpController.

@BeforeEach
public void setUpController() {
    store = mock(Store.class);
    graphFactory = mock(GraphFactory.class);
    userFactory = mock(UserFactory.class);
    examplesFactory = mock(ExamplesFactory.class);
    operationController = new OperationController(graphFactory, userFactory, examplesFactory);
    when(store.getSchema()).thenReturn(new Schema());
    when(store.getProperties()).thenReturn(new StoreProperties());
    Graph graph = new Graph.Builder().config(new GraphConfig("id")).store(store).addSchema(new Schema()).build();
    when(graphFactory.getGraph()).thenReturn(graph);
}
Also used : GraphConfig(uk.gov.gchq.gaffer.graph.GraphConfig) GraphFactory(uk.gov.gchq.gaffer.rest.factory.GraphFactory) Graph(uk.gov.gchq.gaffer.graph.Graph) ExamplesFactory(uk.gov.gchq.gaffer.rest.factory.ExamplesFactory) Schema(uk.gov.gchq.gaffer.store.schema.Schema) Store(uk.gov.gchq.gaffer.store.Store) UserFactory(uk.gov.gchq.gaffer.rest.factory.UserFactory) StoreProperties(uk.gov.gchq.gaffer.store.StoreProperties) BeforeEach(org.junit.jupiter.api.BeforeEach)

Aggregations

BeforeEach (org.junit.jupiter.api.BeforeEach)1 Graph (uk.gov.gchq.gaffer.graph.Graph)1 GraphConfig (uk.gov.gchq.gaffer.graph.GraphConfig)1 ExamplesFactory (uk.gov.gchq.gaffer.rest.factory.ExamplesFactory)1 GraphFactory (uk.gov.gchq.gaffer.rest.factory.GraphFactory)1 UserFactory (uk.gov.gchq.gaffer.rest.factory.UserFactory)1 Store (uk.gov.gchq.gaffer.store.Store)1 StoreProperties (uk.gov.gchq.gaffer.store.StoreProperties)1 Schema (uk.gov.gchq.gaffer.store.schema.Schema)1