public void GetNextPrimeNumberAsync_search_overflows_should_should_throw_exception(int value)
        {
            var service   = new PrimeNumberService(mockLogger.Object);
            var exception = Assert.ThrowsAsync <ArgumentOutOfRangeException>(() => service.GetNextPrimeNumberAsync(value));

            Assert.AreEqual(exception.Message, "Specified argument was out of the range of valid values. (Parameter 'Prime number')");
        }
        public async Task GetNextPrimeNumberAsync_number_in_range_should_return_next_number(int testValue, int nextPrimeNumber)
        {
            var service = new PrimeNumberService(mockLogger.Object);
            var result  = await service.GetNextPrimeNumberAsync(testValue);

            Assert.AreEqual(result, nextPrimeNumber);
        }
        public void GetNextPrimeNumberAsync_number_below_one_range_should_return_two(int[] values)
        {
            var service = new PrimeNumberService(mockLogger.Object);

            values.ToList().ForEach(value =>
            {
                var result = service.GetNextPrimeNumberAsync(value).GetAwaiter().GetResult();
                Assert.AreEqual(result, 2);
            });
        }