If they can't get to the target, they can't shift.
"Must end adjacent to the target" is a conditional that has to be met for the shift to occur. So they can shift 0, 1 or 2 squares, but in order to move at all, the movement must end adjacent to the target.
What is not covered is what happens if the shift is interrupted and they can't continue the shift. If it is, then they go back to their starting location as the triggered action renders the whole move invalid.
That said, as webbcode points out barring an immediate interrupt, or in some cases difficult terrain, since the ally has to be adjacent to you, this restriction should not be a problem.