예제 #1
0
 public void TestFizzBuzz_ShouldReturnFirstThreeItems()
 {
     FizzBuzzMain fizbuzz = new FizzBuzzMain ();
     var expected = new List<string>{ "1", "2", "Fizz" };
     var actual = fizbuzz.GetFizzBuzz (3);
     CollectionAssert.AreEqual (expected, actual);
 }
예제 #2
0
        public void TestFizzBuzz_ShouldReturnTwoIntegers()
        {
            var fizzbuzz = new FizzBuzzMain();
            var expected = new List<string>{ "1", "2" };

            var actual = fizzbuzz.GetFizzBuzz(2);

            CollectionAssert.AreEqual(expected, actual);
        }
예제 #3
0
        public void TestFizzBuzz_ShouldReturnFirstFiveItems()
        {
            FizzBuzzMain fizbuzz  = new FizzBuzzMain();
            var          expected = new List <string> {
                "1", "2", "Fizz", "4", "Buzz"
            };
            var actual = fizbuzz.GetFizzBuzz(5);

            CollectionAssert.AreEqual(expected, actual);
        }
예제 #4
0
        public void TestFizzBuzz_ShouldReturnFizzBuzz()
        {
            FizzBuzzMain fizbuzz = new FizzBuzzMain ();
            var position = 15;
            var expected = "FizzBuzz";

            var actualFizzBuzzList = fizbuzz.GetFizzBuzz(position);
            var actual = actualFizzBuzzList.ElementAt(position - 1);

            Assert.AreEqual(expected, actual);
        }
예제 #5
0
        public void TestFizzBuzz_ShouldReturnFizzBuzz()
        {
            FizzBuzzMain fizbuzz  = new FizzBuzzMain();
            var          position = 15;
            var          expected = "FizzBuzz";

            var actualFizzBuzzList = fizbuzz.GetFizzBuzz(position);
            var actual             = actualFizzBuzzList.ElementAt(position - 1);

            Assert.AreEqual(expected, actual);
        }
예제 #6
0
        public void TestFizzBuzz_ShouldReturnTwoIntegers()
        {
            var fizzbuzz = new FizzBuzzMain();
            var expected = new List <string> {
                "1", "2"
            };

            var actual = fizzbuzz.GetFizzBuzz(2);

            CollectionAssert.AreEqual(expected, actual);
        }