public void Execute(int index) { int count = Reader.BeginForEachIndex(index); Assert.AreEqual(count, index); for (int i = 0; i != index; i++) { Assert.AreEqual(index - i, Reader.RemainingItemCount); var peekedValue = Reader.Peek <int>(); var value = Reader.Read <int>(); Assert.AreEqual(i, value); Assert.AreEqual(i, peekedValue); } }