### Question:
OperationExecutor { public <T> T execute(GraphOperation<? extends OperationResult<T>> operation) { long start = System.nanoTime(); T result = operation.execute(graph).get(); logger.info("[{}] Operation {} completed in {} milliseconds", Thread.currentThread().getName(), operation.getClass().getSimpleName(), elapsedTime(start)); return result; } OperationExecutor(Graph<Vertex, Edge> graph); T execute(GraphOperation<? extends OperationResult<T>> operation);  }### Answer:
@Test public void testExecute() { DirectedGraph<Vertex, Edge> graph = new DefaultDirectedGraph<>(Edge.class); OperationExecutor operationExecutor = new OperationExecutor(graph); String result = operationExecutor.execute(graph1 -> { Assert.assertEquals("Just validate this method was called", graph, graph1); return () -> "Result"; }); Assert.assertEquals("Result", result); }