Add options when calling validate() and update unit tests and readme.