Refactor cleaning up the intersection tests