Skip to content

Commit 3ea7fcd

Browse files
committed
Fix xUnit2013
Do not use Assert.Equal() to check for collection size. Use Assert.Empty instead.
1 parent 6b0cd5f commit 3ea7fcd

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

Source/HttpMultipartParser.UnitTests/ParserScenarios/InvalidPart.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,8 @@ public void Invalid_part_is_ignored()
5454
using (Stream stream = TestUtil.StringToStream(_testCase.Request, Encoding.UTF8))
5555
{
5656
var parser = MultipartFormDataParser.Parse(stream, ignoreInvalidParts: true);
57-
Assert.Equal(0, parser.Files.Count);
58-
Assert.Equal(0, parser.Parameters.Count);
57+
Assert.Empty(parser.Files);
58+
Assert.Empty(parser.Parameters);
5959
}
6060
}
6161

@@ -65,8 +65,8 @@ public async Task Invalid_part_is_ignored_async()
6565
using (Stream stream = TestUtil.StringToStream(_testCase.Request, Encoding.UTF8))
6666
{
6767
var parser = await MultipartFormDataParser.ParseAsync(stream, ignoreInvalidParts: true);
68-
Assert.Equal(0, parser.Files.Count);
69-
Assert.Equal(0, parser.Parameters.Count);
68+
Assert.Empty(parser.Files);
69+
Assert.Empty(parser.Parameters);
7070
}
7171
}
7272
}

0 commit comments

Comments
 (0)