Exemple #1
0
        public void DivideTwoIntegers_DivideByZero_Exception()
        {
            // Arrange
            int a = 5;
            int b = 0;

            // Assert
            Assert.Throws <DivideByZeroException>(()
                                                  => Calculator.DivideTwoIntegers(a, b));
        }
Exemple #2
0
        public void DivideTwoIntegers_InvalidArgument_Exception()
        {
            // Arrange
            int a = 5000;
            int b = 0;

            // Assert
            Assert.Throws <ArgumentException>(()
                                              => Calculator.DivideTwoIntegers(a, b));
        }
Exemple #3
0
 public void JustTest()
 {
     Console.WriteLine(Calculator.DivideTwoIntegers(3, 0));
     Console.WriteLine("Another test");
 }