Skip to content

Commit 1503be5

Browse files
authored
tests: add mtest tests for generic Assert.IsNotInstanceOfType (#351)
1 parent 1e6ed50 commit 1503be5

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/FluentAssertions.Analyzers.Tests/Tips/MsTestTests.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -276,6 +276,7 @@ public void AssertIsInstanceOfType_TestCodeFix(string oldAssertion, string newAs
276276
[DataTestMethod]
277277
[AssertionDiagnostic("Assert.IsNotInstanceOfType(actual, type{0});")]
278278
[AssertionDiagnostic("Assert.IsNotInstanceOfType(actual, typeof(string){0});")]
279+
[AssertionDiagnostic("Assert.IsNotInstanceOfType<string>(actual{0});")]
279280
[Implemented]
280281
public void AssertIsNotInstanceOfType_TestAnalyzer(string assertion) => VerifyCSharpDiagnostic("object actual, Type type", assertion);
281282

@@ -286,6 +287,9 @@ public void AssertIsInstanceOfType_TestCodeFix(string oldAssertion, string newAs
286287
[AssertionCodeFix(
287288
oldAssertion: "Assert.IsNotInstanceOfType(actual, typeof(string){0});",
288289
newAssertion: "actual.Should().NotBeOfType<string>({0});")]
290+
[AssertionCodeFix(
291+
oldAssertion: "Assert.IsNotInstanceOfType<string>(actual{0});",
292+
newAssertion: "actual.Should().NotBeOfType<string>({0});")]
289293
[Implemented]
290294
public void AssertIsNotInstanceOfType_TestCodeFix(string oldAssertion, string newAssertion)
291295
=> VerifyCSharpFix("object actual, Type type", oldAssertion, newAssertion);

0 commit comments

Comments
 (0)