For aligning axes in cartesian machines:
https://www.youmagine.com/designs/alignment-and-calibration-cube
Measure diagonals in each plane- XY, XZ, and YZ to check orthogonality of axes.
There's a spreadsheet that calculates the error angle and required correction.
You can also use it to calibrate steps/mm in all three axes.