add 'required' validation and tests