consolidating and testing validationfailedexception

replaced 2 constructors with 1 constructor using optional parameters.
Tests for constructors as well as getobjectdata.