added isLength test