I think if you feel the pastor's counsel could help you, then you should do it.
I think if you're doing fine by yourself, and/or with the counsel of others, and would be doing it just to expose . . . ehhh.
I happen to be pro-exposure, but I wouldn't ordinarily include a pastor in the small circle to whom I'd recommend exposing. However, again, if YOU need someone to talk to, particularly spiritually, then there's no reason why you need to lie to cover up your husband's affair.