Testing that the viewport is updated correctly when sorting the items