Adjusted shortestPath test to expect the correct result