public void IfConfigHasTwoNumbers_ThatCanDivideSameInput_ReturnCorrectString() { var sut = new FizzBuzzService(1, 100); var dict = new Dictionary<ulong, string> { { 5, "Foo" }, { 3, "Fizz" }, { 4, "Buzz" } }; string actualValue = sut.ProcessFizzBuzz(20, dict); Assert.That(actualValue, Is.EqualTo("FooBuzz")); }
public void IfConfigHasCompositeNumber_ThatCanDivideInput_AndPairOfFactorsExist_ReturnCorrectString() { var sut = new FizzBuzzService(1, 100); var dict = new Dictionary<ulong, string> { { 12, "Foo" }, { 3, "Fizz" }, { 4, "Buzz" } }; string actualValue = sut.ProcessFizzBuzz(24, dict); Assert.That(actualValue, Is.EqualTo("FizzBuzz")); }
public void IfConfigHasPrimeNumber_ThatCanDivideInput_ReturnCorrectString() { var sut = new FizzBuzzService(1, 100); var dict = new Dictionary<ulong, string> { { 3, "Foo" } }; string actualValue = sut.ProcessFizzBuzz(39, dict); Assert.That(actualValue, Is.EqualTo(dict[3])); }
public void CanProgramAcceptLongNumbers() { var sut = new FizzBuzzService(1, 100); var dict = new Dictionary<ulong, string> { { 5, "Foo" }, { 3, "Fizz" } }; string actualValue = sut.ProcessFizzBuzz(ulong.MaxValue, dict); Assert.That(actualValue, Is.EqualTo("FooFizz")); }