private void CorrectReturnedFizzBuzzAnswerCheck2() { AnswerFactory testFactory = new ConcreteAnswerFactory(); Answer receivedAnswer = testFactory.getAnswer(60); TestClass.AreTrue(receivedAnswer.GetType() == typeof(FizzBuzz), "Should return FizzBuzz"); }
private void CorrectReturnedFizzAnswer() { AnswerFactory testFactory = new ConcreteAnswerFactory(); Answer receivedAnswer = testFactory.getAnswer(3); TestClass.AreEqual(true, receivedAnswer.GetType() == typeof(Fizz), "Should return Fizz"); }
private void ShouldNotReturnNumberAnswer() { AnswerFactory testFactory = new ConcreteAnswerFactory(); Answer shouldNotBeNumber = testFactory.getAnswer(10); TestClass.AreNotEqual(new Number(1), shouldNotBeNumber, "Should not return Number"); }
private void ShouldNotReturnBuzzAnswer() { AnswerFactory testFactory = new ConcreteAnswerFactory(); Answer receivedAnswer = testFactory.getAnswer(4); TestClass.AreFalse(receivedAnswer.GetType() == typeof(Buzz), "Should not return Buzz"); }
private void CorrectReturnedNumberAnswer() { AnswerFactory testFactory = new ConcreteAnswerFactory(); Answer receivedAnswer = testFactory.getAnswer(1); TestClass.AreEqual(true, receivedAnswer.GetType() == typeof(Number), "Should return Number"); }