public async Task <IActionResult> Index()
        {
            _pipeline = await _pipelineAlloc.RetrievePipeline();

            await _pipeline.FillPipeline(new Default());

            await _pipeline.FillPipeline(new Default());

            _pipeline.Complete();
            await _pipeline.WaitForResults();

            var results = await _pipeline.GetResults();

            ViewBag.Results = results;

            _pipeline = await _pipelineAlloc.RetrievePipeline();

            List <Default> inputs = new List <Default>();

            inputs.Add(new Default("Forget Pipeline", 300));
            inputs.Add(new Default("Forget Pipeline Two", 300));
            _pipeline.ProcessAndForget(inputs);

            return(View());
        }
        public void TestDefaultPipeline(string message, int number)
        {
            IPipelineAlloc <DefaultPipeline> pipelineAlloc = new PipelineAlloc <DefaultPipeline>();
            IPipeline <Default> pipeline = pipelineAlloc.RetrievePipeline().Result;

            pipeline.FillPipeline(new Default(message, number));
            pipeline.Complete();
            pipeline.WaitForResults().Wait();
            var result = pipeline.GetResults().Result;
            var item   = result.FirstOrDefault();

            Assert.True(result.Count == 1);
            Assert.Equal(item.message, message);
            Assert.Equal(item.randomNumber, number);
        }