Do not guess the direction of your stepper motor any longer while developing code - just use a clockhand-style pointer.
These parts are press-fit for NEMA17 axis, just print it with an as-fine-as-possible setting (I used 0.1mm Layers in Prusament PETG) and snap it onto the stepper motor.
There is a skinny and a bold version of the pointer, see the files attached.
The author marked this model as their own original creation.