Factor out order tests