More unit tests and validations