Skip to content

Null checks on delegates #1117

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

Merged
merged 1 commit into from
Aug 18, 2019
Merged

Conversation

jnyrup
Copy link
Member

@jnyrup jnyrup commented Aug 18, 2019

When asserting on delegates we do not check if the delegate is non-null before invoking it.

FailIfSubjectIsAsyncVoid is changed so it does not run for AsyncFunctionAssertions via a new CanHandleAsync property.
The reason it worked before, was that ExecuteInDefaultSynchronizationContext wrapped an async Task method in a Task method.

@jnyrup jnyrup merged commit d55545a into fluentassertions:master Aug 18, 2019
@jnyrup jnyrup deleted the NullActions branch August 18, 2019 17:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants