From bbd8b360baaab8f68738bd71ea738d5266d7d40e Mon Sep 17 00:00:00 2001 From: Meir Blachman Date: Mon, 20 May 2024 23:14:01 +0300 Subject: [PATCH] tests: add mtest tests for generic Assert.IsNotInstanceOfType --- src/FluentAssertions.Analyzers.Tests/Tips/MsTestTests.cs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/FluentAssertions.Analyzers.Tests/Tips/MsTestTests.cs b/src/FluentAssertions.Analyzers.Tests/Tips/MsTestTests.cs index 3fe27698..f18daa09 100644 --- a/src/FluentAssertions.Analyzers.Tests/Tips/MsTestTests.cs +++ b/src/FluentAssertions.Analyzers.Tests/Tips/MsTestTests.cs @@ -276,6 +276,7 @@ public void AssertIsInstanceOfType_TestCodeFix(string oldAssertion, string newAs [DataTestMethod] [AssertionDiagnostic("Assert.IsNotInstanceOfType(actual, type{0});")] [AssertionDiagnostic("Assert.IsNotInstanceOfType(actual, typeof(string){0});")] + [AssertionDiagnostic("Assert.IsNotInstanceOfType(actual{0});")] [Implemented] public void AssertIsNotInstanceOfType_TestAnalyzer(string assertion) => VerifyCSharpDiagnostic("object actual, Type type", assertion); @@ -286,6 +287,9 @@ public void AssertIsInstanceOfType_TestCodeFix(string oldAssertion, string newAs [AssertionCodeFix( oldAssertion: "Assert.IsNotInstanceOfType(actual, typeof(string){0});", newAssertion: "actual.Should().NotBeOfType({0});")] + [AssertionCodeFix( + oldAssertion: "Assert.IsNotInstanceOfType(actual{0});", + newAssertion: "actual.Should().NotBeOfType({0});")] [Implemented] public void AssertIsNotInstanceOfType_TestCodeFix(string oldAssertion, string newAssertion) => VerifyCSharpFix("object actual, Type type", oldAssertion, newAssertion);