During a review I noticed that in e.g. AnalyzeWhenTypedCustomComparerProvided we don't have a ↓.
|
public void AnalyzeWhenTypedCustomComparerProvided() |
|
{ |
|
var testCode = TestUtility.WrapInTestMethod($@" |
|
var actual = new[] {{ ""1"", ""2"", ""3"" }}; |
|
Assert.That(actual, {this.constraint}(1).Using((IEqualityComparer<string>)StringComparer.Ordinal));", |
|
"using System.Collections.Generic;"); |
|
|
|
RoslynAssert.Diagnostics(analyzer, |
|
expectedDiagnostic.WithMessage($"The '{this.constraint}' constraint cannot be used with actual argument of type 'string[]' and expected argument of type 'int'"), |
|
testCode); |
|
} |
This is not a major problem - and I guess we only have a few tests like this, but to make the tests more precise we should check that all tests with RoslynAssert.Diagnostics, RoslynAssert.CodeFix or RoslynAssert.Suppressed contains a ↓ in the expected location.
EDIT: Full list of RoslynAssert... that we currently use
RoslynAssert.CodeFix
RoslynAssert.Diagnostics
RoslynAssert.FixAll
RoslynAssert.NoAnalyzerDiagnostics
RoslynAssert.NoFix
RoslynAssert.NotSuppressed
RoslynAssert.Suppressed
RoslynAssert.Valid
During a review I noticed that in e.g.
AnalyzeWhenTypedCustomComparerProvidedwe don't have a↓.nunit.analyzers/src/nunit.analyzers.tests/SomeItemsIncompatibleTypes/SomeItemsIncompatibleTypesAnalyzerTests.cs
Lines 143 to 153 in 8bce842
This is not a major problem - and I guess we only have a few tests like this, but to make the tests more precise we should check that all tests with
RoslynAssert.Diagnostics,RoslynAssert.CodeFixorRoslynAssert.Suppressedcontains a↓in the expected location.EDIT: Full list of RoslynAssert... that we currently use