public async Task PushToLimitedListWithFunc()
        {
            var asyncEnum = new ReplayAsyncEnumerable <int>();
            var list      = new List <int>();
            var max       = 5;
            var task      = asyncEnum.PushToList(list, () => max).LastAsync();

            Assert.Empty(list);

            for (int i = 0; i < 7; i++)
            {
                await asyncEnum.Next(i);
            }

            await Task.Delay(500);

            Assert.Equal(5, list.Count);

            max = 2;

            for (int i = 0; i < 4; i++)
            {
                await asyncEnum.Next(i);
            }

            await asyncEnum.Complete();

            await task;

            Assert.Equal(2, list.Count);
        }