Beispiel #1
0
            public void ReturnsFalseWhenHeaderCannotBeFound()
            {
                var headers = new HttpConnectHeaders();

                headers.Add("x-header", "value");

                headers.TryGetValue("UNKNOWN", out string _).Should().BeFalse();
            }
Beispiel #2
0
            public void ReturnsTrueWhenHeaderCanBeFound()
            {
                var headers = new HttpConnectHeaders();

                headers.Add("x-header", "value");

                headers.TryGetValue("x-header", out string _).Should().BeTrue();
            }
Beispiel #3
0
            public void ReturnsNullInOutParameterWhenHeaderCannotBeFound()
            {
                var headers = new HttpConnectHeaders();

                headers.Add("x-header", "my-value");

                headers.TryGetValue("UNKNOWN", out string value);

                value.Should().BeNull();
            }