Added sorting tests