Skip to content
This repository was archived by the owner on Nov 20, 2018. It is now read-only.

Commit 1a7279f

Browse files
committed
Update tests
1 parent 7bb3170 commit 1a7279f

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

test/Microsoft.AspNetCore.Http.Tests/HeaderDictionaryTests.cs

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33

44
using System;
55
using System.Collections.Generic;
6+
using System.Linq;
67
using Microsoft.Extensions.Primitives;
78
using Xunit;
89

@@ -15,7 +16,9 @@ public class HeaderDictionaryTests
1516
new[] { "Value1", "Value2", "Value3", "Value4" },
1617
new[] { "Value1", "", "Value3", "Value4" },
1718
new[] { "Value1", "", "", "Value4" },
18-
new[] { "", "", "", "" }
19+
new[] { "Value1", "", " ", "Value4" },
20+
new[] { "", "", "", "" },
21+
new[] { "", " ", "", " " }
1922
};
2023

2124
[Fact]
@@ -48,8 +51,9 @@ public void EmptyHeaderSegmentsAreParsable(IEnumerable<string> segments)
4851
});
4952

5053
var result = headers.GetCommaSeparatedValues("Header1");
54+
var expectedResult = segments.Where(s => !string.IsNullOrWhiteSpace(s));
5155

52-
Assert.Equal(segments, result);
56+
Assert.Equal(expectedResult, result);
5357
}
5458
}
5559
}

0 commit comments

Comments
 (0)