The answer to that question would depend on how the employer has treated other applicants of the opposite gender in same situation (that is, being married to a female). The law hinges on disparate treatment; it does not account for what the employer cares about.