I know this may sound obvious but will ask just to cover all base's. . . . You have wired it correct, it's not out phase is it.
If you havent already, I'd start at the begining and trace my way through then if all seems ok start swapping with other axis
Swapping with 1 of the other axis motors to see if it moves, that way you'll know if it's the motor or the drive.?
If it's doing it off the machine and moves when you change axis then it sounds like a miss wire or a knackerd motor to me.?