Yes, It does not calculate shortest path b/w any two vertices:-

A

/ \

B---C

(Here A, B and C forms a cycle, Graph is undirected as stated in question.)

Performing BFS on A, we get BFT of this graph-

A

/ \

B C

In this BFT, distance between B to C is 2 (B-A-C) but actual shortest distance is one.

A

/ \

B---C

(Here A, B and C forms a cycle, Graph is undirected as stated in question.)

Performing BFS on A, we get BFT of this graph-

A

/ \

B C

In this BFT, distance between B to C is 2 (B-A-C) but actual shortest distance is one.