I have been thinking about this too. The solution I came up with is to make sure that the diagonals of the frame cross in the same plane.

Get a straight edge and lay it from corner to corner. Now measure down (using a dial gague or caliper) from the centre of this staight edge to a fixed point and record the measurement. Lay the straight edge across the other two corners and measure down to the same fixed point. If the measurement is the same, you know your frame has no twist in it.