Added tests for uniqueness and validation.