public void Should_behave_correctly()
        {
            var items   = new[] { 1, 2, 3 };
            var subject = new ReadAheadEnumerable <int>(items);

            var enumerator = (ReadAheadEnumerable <int> .ReadAheadEnumerator)subject.GetEnumerator();

            Action act = () => { int temp = enumerator.Current; };

            act.ShouldThrow <InvalidOperationException>();

            enumerator.MoveNext().Should().BeTrue();
            enumerator.Current.Should().Be(1);
            enumerator.HasNext.Should().BeTrue();

            enumerator.MoveNext().Should().BeTrue();
            enumerator.Current.Should().Be(2);
            enumerator.HasNext.Should().BeTrue();

            enumerator.MoveNext().Should().BeTrue();
            enumerator.Current.Should().Be(3);
            enumerator.HasNext.Should().BeFalse();

            enumerator.MoveNext().Should().BeFalse();

            act = () => { int temp = enumerator.Current; };
            act.ShouldThrow <InvalidOperationException>();
        }
        public void Should_return_all_items()
        {
            var items   = new[] { 1, 2, 3 };
            var subject = new ReadAheadEnumerable <int>(items);

            var list = subject.ToList();

            list.Count.Should().Be(3);
            list.Should().ContainInOrder(1, 2, 3);
        }