Example #1
0
        public void ValidateCustomTranslations()
        {
            var translations = FizzBuzz.DefaultTranslations;

            translations.Add(new Translation((x) => x.ToString().Contains('3'), "Fizz"));

            Assert.Equal("Fizz", FizzBuzz.Print(13, translations));
        }
Example #2
0
 public void ValidatePrintRange()
 {
     Assert.Equal(ExpectedOutputOfRange_1_to_30, FizzBuzz.Print(1, 30, FizzBuzz.DefaultTranslations));
 }
Example #3
0
 public void ValidatePrint(int input, string expectedOutput)
 {
     Assert.Equal(expectedOutput, FizzBuzz.Print(input, FizzBuzz.DefaultTranslations));
 }