Fixed issues found by unit tests , fixed date validation (REF-204,205)