Exemplo n.º 1
0
        public void Given_2_When_GetPrimeFactorCalled_Then_ShouldReturnListThatContains2(int number, int[] expectedList)
        {
            var primeFactorGenerator = new PrimeFactorGenerator();
            var primeFactorList      = primeFactorGenerator.GetAllPrimeFactors(number);

            Assert.That(primeFactorList, Is.EqualTo(expectedList));
        }
Exemplo n.º 2
0
        public void Given_1_When_GetPrimeFactorCalled_Then_ShouldReturnEmptyList()
        {
            var primeFactorGenerator = new PrimeFactorGenerator();
            var primeFactorList      = primeFactorGenerator.GetAllPrimeFactors(1);

            Assert.That(primeFactorList, Is.EqualTo(new List <int>()));
        }
Exemplo n.º 3
0
 public void Given_2_When_GetPrimeFactorCalled_Then_ShouldReturnListThatContains2(int number, int[] expectedList)
 {
     var primeFactorGenerator = new PrimeFactorGenerator();
     var primeFactorList = primeFactorGenerator.GetAllPrimeFactors(number);
     Assert.That(primeFactorList, Is.EqualTo(expectedList));
 }
Exemplo n.º 4
0
 public void Given_1_When_GetPrimeFactorCalled_Then_ShouldReturnEmptyList()
 {
     var primeFactorGenerator=new PrimeFactorGenerator();
     var primeFactorList=primeFactorGenerator.GetAllPrimeFactors(1);
     Assert.That(primeFactorList,Is.EqualTo(new List<int>()));
 }