Quantcast
Channel: Fluent Assertions
Viewing all articles
Browse latest Browse all 1402

New Post: Equals cannot match generic List correctly

$
0
0

I just upgraded to 2.0 and I have following code to test list values

 

            actualResponse.MyObject.Group
                .Should().NotBeEmpty()
                .And.Should().NotBeNull()
                .And.Should().Equals(new List<string> { "group1", "group2" });

MyObject.Group has data type of List<string>, no matter what values I have in Equals, the test always passes.


Viewing all articles
Browse latest Browse all 1402

Trending Articles