System.Tests.StringTests.IndexOfAny C# (CSharp) Method

IndexOfAny() private method

private IndexOfAny ( string s, char anyOf, int startIndex, int count, int expected ) : void
s string
anyOf char
startIndex int
count int
expected int
return void
        public static void IndexOfAny(string s, char[] anyOf, int startIndex, int count, int expected)
        {
            if (startIndex + count == s.Length)
            {
                if (startIndex == 0)
                {
                    Assert.Equal(expected, s.IndexOfAny(anyOf));
                }
                Assert.Equal(expected, s.IndexOfAny(anyOf, startIndex));
            }
            Assert.Equal(expected, s.IndexOfAny(anyOf, startIndex, count));
        }
StringTests