@@ -259,14 +259,18 @@ public class CollectionTests
259259
260260 [ AssertionDataTestMethod ]
261261 [ AssertionDiagnostic ( "actual.Should().NotBeNull().And.NotBeEmpty({0});" ) ]
262- [ NotImplemented ]
262+ [ AssertionDiagnostic ( "actual.Should().NotBeEmpty().And.NotBeNull({0});" ) ]
263+ [ Implemented ]
263264 public void CollectionShouldNotBeNullOrEmpty_TestAnalyzer ( string assertion ) => VerifyCSharpDiagnostic < CollectionShouldNotBeNullOrEmptyAnalyzer > ( assertion ) ;
264265
265266 [ AssertionDataTestMethod ]
266267 [ AssertionCodeFix (
267- oldAssertion : "actual.Should().NotBeNull({0}).And.NotBeEmpty({0});" ,
268- newAssertion : "actual.Should().NotBeNullOrEmpty({0});" ) ]
269- [ NotImplemented ]
268+ oldAssertion : "actual.Should().NotBeNull().And.NotBeEmpty({0});" ,
269+ newAssertion : "actual.Should().NotBeNullOrEmpty({0});" ) ]
270+ [ AssertionCodeFix (
271+ oldAssertion : "actual.Should().NotBeEmpty().And.NotBeNull({0});" ,
272+ newAssertion : "actual.Should().NotBeNullOrEmpty({0});" ) ]
273+ [ Implemented ]
270274 public void CollectionShouldNotBeNullOrEmpty_TestCodeFix ( string oldAssertion , string newAssertion ) => VerifyCSharpFix < CollectionShouldNotBeNullOrEmptyCodeFix , CollectionShouldNotBeNullOrEmptyAnalyzer > ( oldAssertion , newAssertion ) ;
271275
272276 [ AssertionDataTestMethod ]
@@ -326,15 +330,15 @@ public class CollectionTests
326330 public void CollectionShouldBeInDescendingOrder_TestCodeFix ( string oldAssertion , string newAssertion ) => VerifyCSharpFix < CollectionShouldBeInDescendingOrderCodeFix , CollectionShouldBeInDescendingOrderAnalyzer > ( oldAssertion , newAssertion ) ;
327331
328332 [ AssertionDataTestMethod ]
329- [ AssertionDiagnostic ( "actual.Select(e1 => e1.SomeProperty ).Should().Equal(expected.Select(e2 => e2.SomeProperty ){0});" ) ]
330- [ NotImplemented ]
333+ [ AssertionDiagnostic ( "actual.Select(e1 => e1.BooleanProperty ).Should().Equal(expected.Select(e2 => e2.BooleanProperty ){0});" ) ]
334+ [ Implemented ]
331335 public void CollectionShouldEqualOtherCollectionByComparer_TestAnalyzer ( string assertion ) => VerifyCSharpDiagnostic < CollectionShouldEqualOtherCollectionByComparerAnalyzer > ( assertion ) ;
332336
333337 [ AssertionDataTestMethod ]
334338 [ AssertionCodeFix (
335- oldAssertion : "actual.Select(e1 => e1.SomeProperty ).Should().Equal(expected.Select(e2 => e2.SomeProperty ){0});" ,
336- newAssertion : "actual.Should().Equal(expected, (e1, e2) => e1.SomeProperty == e2.SomeProperty {0});" ) ]
337- [ NotImplemented ]
339+ oldAssertion : "actual.Select(e1 => e1.BooleanProperty ).Should().Equal(expected.Select(e2 => e2.BooleanProperty ){0});" ,
340+ newAssertion : "actual.Should().Equal(expected, (e1, e2) => e1.BooleanProperty == e2.BooleanProperty {0});" ) ]
341+ [ Implemented ]
338342 public void CollectionShouldEqualOtherCollectionByComparer_TestCodeFix ( string oldAssertion , string newAssertion ) => VerifyCSharpFix < CollectionShouldEqualOtherCollectionByComparerCodeFix , CollectionShouldEqualOtherCollectionByComparerAnalyzer > ( oldAssertion , newAssertion ) ;
339343
340344 [ AssertionDataTestMethod ]
@@ -344,8 +348,8 @@ public class CollectionTests
344348
345349 [ AssertionDataTestMethod ]
346350 [ AssertionCodeFix (
347- oldAssertion : "actual.Intersect(expected).Should().BeEmpty({0});" ,
348- newAssertion : "actual.Should().NotIntersectWith(expected{0});" ) ]
351+ oldAssertion : "actual.Intersect(expected).Should().BeEmpty({0});" ,
352+ newAssertion : "actual.Should().NotIntersectWith(expected{0});" ) ]
349353 [ Implemented ]
350354 public void CollectionShouldNotIntersectWith_TestCodeFix ( string oldAssertion , string newAssertion ) => VerifyCSharpFix < CollectionShouldNotIntersectWithCodeFix , CollectionShouldNotIntersectWithAnalyzer > ( oldAssertion , newAssertion ) ;
351355
@@ -376,37 +380,41 @@ public class CollectionTests
376380
377381 [ AssertionDataTestMethod ]
378382 [ AssertionDiagnostic ( "actual.Should().HaveSameCount(actual.Distinct(){0});" ) ]
379- [ NotImplemented ]
383+ [ Implemented ]
380384 public void CollectionShouldOnlyHaveUniqueItems_TestAnalyzer ( string assertion ) => VerifyCSharpDiagnostic < CollectionShouldOnlyHaveUniqueItemsAnalyzer > ( assertion ) ;
381385
382386 [ AssertionDataTestMethod ]
383387 [ AssertionCodeFix (
384388 oldAssertion : "actual.Should().HaveSameCount(actual.Distinct(){0});" ,
385389 newAssertion : "actual.Should().OnlyHaveUniqueItems({0});" ) ]
386- [ NotImplemented ]
390+ [ Implemented ]
387391 public void CollectionShouldOnlyHaveUniqueItems_TestCodeFix ( string oldAssertion , string newAssertion ) => VerifyCSharpFix < CollectionShouldOnlyHaveUniqueItemsCodeFix , CollectionShouldOnlyHaveUniqueItemsAnalyzer > ( oldAssertion , newAssertion ) ;
388392
389393 [ AssertionDataTestMethod ]
390394 [ AssertionDiagnostic ( "actual.Select(x => x.BooleanProperty).Should().OnlyHaveUniqueItems({0});" ) ]
391- [ NotImplemented ]
395+ [ Implemented ]
392396 public void CollectionShouldOnlyHaveUniqueItemsByComparer_TestAnalyzer ( string assertion ) => VerifyCSharpDiagnostic < CollectionShouldOnlyHaveUniqueItemsByComparerAnalyzer > ( assertion ) ;
393397
394398 [ AssertionDataTestMethod ]
395399 [ AssertionCodeFix (
396400 oldAssertion : "actual.Select(x => x.BooleanProperty).Should().OnlyHaveUniqueItems({0});" ,
397401 newAssertion : "actual.Should().OnlyHaveUniqueItems(x => x.BooleanProperty{0});" ) ]
398- [ NotImplemented ]
402+ [ Implemented ]
403+ [ Ignore ( "Will be available in Fluent Assertions 5.0" ) ]
399404 public void CollectionShouldOnlyHaveUniqueItemsByComparer_TestCodeFix ( string oldAssertion , string newAssertion ) => VerifyCSharpFix < CollectionShouldOnlyHaveUniqueItemsByComparerCodeFix , CollectionShouldOnlyHaveUniqueItemsByComparerAnalyzer > ( oldAssertion , newAssertion ) ;
405+
400406 [ AssertionDataTestMethod ]
401407 [ AssertionDiagnostic ( "actual.FirstOrDefault().Should().BeNull({0});" ) ]
402408 [ NotImplemented ]
409+ [ Ignore ( "What Should Happen?" ) ]
403410 public void CollectionShouldHaveElementAt0Null_TestAnalyzer ( string assertion ) => VerifyCSharpDiagnostic < CollectionShouldHaveElementAt0NullAnalyzer > ( assertion ) ;
404411
405412 [ AssertionDataTestMethod ]
406413 [ AssertionCodeFix (
407414 oldAssertion : "actual.FirstOrDefault().Should().BeNull({0});" ,
408415 newAssertion : "actual.Should().HaveElementAt(0, null{0});" ) ]
409416 [ NotImplemented ]
417+ [ Ignore ( "What Should Happen?" ) ]
410418 public void CollectionShouldHaveElementAt0Null_TestCodeFix ( string oldAssertion , string newAssertion ) => VerifyCSharpFix < CollectionShouldHaveElementAt0NullCodeFix , CollectionShouldHaveElementAt0NullAnalyzer > ( oldAssertion , newAssertion ) ;
411419
412420 private void VerifyCSharpDiagnostic < TDiagnosticAnalyzer > ( string sourceAssersion ) where TDiagnosticAnalyzer : Microsoft . CodeAnalysis . Diagnostics . DiagnosticAnalyzer , new ( )
0 commit comments