System.Linq.Tests.WhereTests.IndexOverflows C# (CSharp) Method

IndexOverflows() private method

private IndexOverflows ( ) : void
return void
        public void IndexOverflows()
        {
            var infiniteWhere = new FastInfiniteEnumerator<int>().Where((e, i) => true);
            using (var en = infiniteWhere.GetEnumerator())
                Assert.Throws<OverflowException>(() =>
                {
                    while (en.MoveNext())
                    {
                    }
                });
        }
WhereTests