More complex test case.
Fixed the validation for optional fields that have a value.