Пример #1
0
        public void ParseStringWithHeaders(string actual, string expected)
        {
            var actualResult = ParseUtility.ParseString(
                new HeaderStruct(() => new[] { actual }),
                string.Empty);

            actualResult.Should().Be(expected);

            actualResult = ParseUtility.ParseString(
                new HeaderStruct(() => new List<string> { actual }),
                string.Empty);

            actualResult.Should().Be(expected);
        }
Пример #2
0
        public void ParseString(string actual, string expected)
        {
            var actualResult = ParseUtility.ParseString(
                (object)null,
                new FuncGetter<object>((carrier, name) => new[] { actual }),
                string.Empty);

            actualResult.Should().Be(expected);

            actualResult = ParseUtility.ParseString(
                (object)null,
                new FuncGetter<object>((carrier, name) => new List<string> { actual }),
                string.Empty);

            actualResult.Should().Be(expected);
        }