Shortest path dont contain any "positive weight cycles". Let us see this with the help of an example
suppose the cost of A to B is 2;B to C is 5;and A to Cis:3; and this is the subgraph of a graph for which we have to calculate the shortest path. Now this cycle cant exist in the graph as we cant have all these 3 edges (u can check this by applying any shortest path algo).