-
Notifications
You must be signed in to change notification settings - Fork 337
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support ArgumentException
for the GuardClauseAssertion
#1107
Comments
I'm torn about it. I see the need but it opens a can of use cases, like "accepted integer must be greater than zero". |
@Kralizek Could you please elaborate a bit more? The current issue is to accept the |
@zvirja oh really? Shame on me! I couldn't find how to do it! Then nevermind! 😁 |
Currently
GuardClauseAssertion
supports onlyArgumentNullException
for the null guard. It's very inconvenient, as sometimes you are checking inputs like following:I suggest to also allow
ArgumentException
with the right parameter name, as it's still a valid guard clause.The text was updated successfully, but these errors were encountered: