Validation, methods and testing

Changed some of the validation and methods. Also started testing the
constructor and the validation within it.