Added length validation for textfield and testing