added validations and unit test to Articles-model