Example #1
0
        private static async Task <IParsedDocumentHolder> ProcessItem(SemaphoreSlim semaphore, MainAspectHandler aspectHandler, IParsedDocumentHolder review)
        {
            try
            {
                await semaphore.WaitAsync().ConfigureAwait(false);

                Document parsedDoc = await review.GetParsed().ConfigureAwait(false);

                Text.Data.IParsedReview parseReview = TestHelper.Instance.ContainerHelper.Resolve <Func <Document, IParsedReviewManager> >()(parsedDoc).Create();
                aspectHandler.Process(parseReview);
                return(review);
            }
            finally
            {
                semaphore.Release();
            }
        }
 public void Arguments()
 {
     Assert.Throws <ArgumentNullException>(() => instance.Process(null));
 }