Tests rearrangement