Covered shortest path distance and path similarity with tests