fluentassertions.analyzers icon indicating copy to clipboard operation
fluentassertions.analyzers copied to clipboard

Analyzers based on the FluentAssertions best practices docs

Results 46 fluentassertions.analyzers issues
Sort by recently updated
recently updated
newest added

The default Roslyn analyzer template allows one to run the analyzer in a Visual Studio Debug instance, which makes debugging your analyzers incredibly easy. This project does not have Visual...

enhancement

https://github.com/fluentassertions/fluentassertions/blob/5.2.0/docs/_data/tips/nullables.yml

enhancement

When applying the codefix for `CollectionShouldNotContainProperty`, the comparison inside the lambda should also be negated. ```c# actual.Should().OnlyContain(x => x.OtherProperty == expectedValue); // before actual.Should().NotContain(x => x.OtherProperty == expectedValue); // after...

bug

Nice project! I've attached a project with failing tests for all the before and after examples I listed in the Fluent Assertions docs. [UnitTests2.zip](https://github.com/Meir017/FluentAssertions.BestPractices/files/1367205/UnitTests2.zip)

### Description I added fluentassertions.analyzers to a solution (with >100 projects) that I can I fix/improve my assertions. But based on the missing common prefix in the DiagnosticId/Code it is...

enhancement

First or all, thank you for this project, looks very useful. Second, sorry if this is a duplicate, I've tried to look around in the open or closed issues. ###...

enhancement

### Description I find that the analyzers should warn people if they say `.Should().ThrowAsync()` and similar, without actually awaiting the task produced by Fluent Assertions. ### Complete minimal example reproducing...

enhancement

for this https://github.com/shouldly/shouldly

enhancement

see https://github.com/fluentassertions/fluentassertions/pull/2422/files