}
@Test
public void testEdgesById() throws Exception {
String processInstance = PROCESS_ENTITY_NAME + "/2014-01-01T01:00Z";
Vertex vertex = service.getGraph().getVertices(
RelationshipProperty.NAME.getName(), processInstance).iterator().next();
Edge edge = vertex.getEdges(Direction.OUT,
RelationshipLabel.PROCESS_CLUSTER_EDGE.getName()).iterator().next();
Vertex toVertex = edge.getVertex(Direction.IN);
LineageMetadataResource resource = new LineageMetadataResource();
Response response = resource.getEdge(String.valueOf(edge.getId()));
Assert.assertEquals(response.getStatus(), Response.Status.OK.getStatusCode());
Map results = (Map) JSONValue.parse(response.getEntity().toString());
Map vertexProperties = (Map) results.get(LineageMetadataResource.RESULTS);
Assert.assertEquals(vertexProperties.get("_id").toString(), edge.getId().toString());
Assert.assertEquals(vertexProperties.get("_outV"), vertex.getId());
Assert.assertEquals(vertexProperties.get("_inV"), toVertex.getId());
}