Added validations for product and updated tests.