public void WhenSubFiveAndThreeGotTwo()
        {
            MathCalculator calculator = new MathCalculator();
            var            result     = calculator.Sub(Five, Three);

            Assert.Equal(2, result);
        }
        public void WhenSubFiveAndNegativeFiveGotNegativeOne()
        {
            MathCalculator calculator = new MathCalculator();
            var            result     = calculator.Sub(Five, -Five);

            Assert.Equal(10, result);
        }
        public void WhenSumStringFiveAndThreeGotEight()
        {
            MathCalculator calculator = new MathCalculator();
            var            result     = calculator.Sum(Five.ToString(), Three.ToString());

            Assert.Equal(Eight, result);
        }
        public void WhenMultStringFiveAndBeliberdaGotNull()
        {
            MathCalculator calculator = new MathCalculator();
            var            result     = calculator.Mult("ww112", Five.ToString());

            Assert.Equal(0, result);
        }
        public void WhenSubThreeAndNullGotException()
        {
            MathCalculator calculator = new MathCalculator();
            var            result     = calculator.Sub(Three, 0);

            Assert.Equal(Three, result);
        }
        public void WhenMultStringFiveAndThreeGot15()
        {
            MathCalculator calculator = new MathCalculator();
            var            result     = calculator.Mult(Five.ToString(), Three.ToString());

            Assert.Equal(15, result);
        }
        public void WhenMultStringBeliberdaAndFiveGotNull()
        {
            MathCalculator calculator = new MathCalculator();
            var            result     = calculator.Mult(Five.ToString(), "ww112");

            Assert.Equal(0, result);
        }
        public void WhenSubStringFiveAndThreeGotTwo()
        {
            MathCalculator calculator = new MathCalculator();
            var            result     = calculator.Sub(Five.ToString(), Three.ToString());

            Assert.Equal(2, result);
        }
        public void WhenSumStringBeliberdaAndFiveGotNull()
        {
            MathCalculator calculator = new MathCalculator();
            var            result     = calculator.Sum("www1", Five.ToString());

            Assert.Equal(0, result);
        }
Exemplo n.º 10
0
        public void WhenSumStringFiveAndBeliberdaGotNull()
        {
            MathCalculator calculator = new MathCalculator();
            var            result     = calculator.Sum(Five.ToString(), "wwww");

            Assert.Equal(0, result);
        }
Exemplo n.º 11
0
        public void WhenSumThreeAndNegativeThreeGotNull()
        {
            MathCalculator calculator = new MathCalculator();
            var            result     = calculator.Sum(Three, -Three);

            Assert.Equal(0, result);
        }
Exemplo n.º 12
0
        public void WhenSubFiveFromFourThenGotOne()
        {
            MathCalculator calculator = new MathCalculator();

            var result = calculator.Sub(4, 5);

            Assert.Equal(Four - Five, result);
        }
Exemplo n.º 13
0
        public void WhenSubFiveFromFourThenGotTwo()
        {
            MathCalculator calculator = new MathCalculator();

            var result = calculator.Sub(5, 3);

            Assert.Equal(Five - Three, result);
        }
Exemplo n.º 14
0
        public void WhenDivFiveAndThreeThenGotTwo()
        {
            MathCalculator calculator = new MathCalculator();

            var result = calculator.Div(Five, Three);

            Assert.Equal(1, result);
        }
Exemplo n.º 15
0
        public void WhenSumFiveAndThreeThenGotEight()
        {
            // Arrage
            MathCalculator calculator = new MathCalculator();
            // Act
            var result = calculator.Sum(Five, Three);

            // Assert
            Assert.Equal(8, result);
        }
        public void WhenSubThreeFromFiveThenGotTwo()
        {
            // Arrange
            MathCalculator calculator = new MathCalculator();

            // Act
            var result = calculator.Sub(Five, Three);

            // Assert
            Assert.Equal(2, result);
        }
Exemplo n.º 17
0
        public void WhenSubMinusFiveAndThreeThanGotMinusEight()
        {
            // Arrange
            MathCalculator calculator = new MathCalculator();

            // Act
            var result = calculator.Sub(-Five, Three);

            // Assert
            Assert.Equal(-8, result);
        }
Exemplo n.º 18
0
        public void WhenSumMuniusFiveAndThreeThenGotMuniusTwo()
        {
            // Arrange(Подготовка данных)
            MathCalculator calculator = new MathCalculator();

            // Act
            int results = calculator.Sum(-Five, Three);

            // Assert
            Assert.Equal(-Five + Three, results);
        }
Exemplo n.º 19
0
        public void WhenSubFiveAndThreeThenGotTwo()
        {
            //Arrange
            MathCalculator calculator = new MathCalculator();

            //Act
            var result2 = calculator.Sub(Five, Three);

            //Assert
            Assert.Equal(Five - Three, result2)
        }
Exemplo n.º 20
0
        public void WhenSumFiveAndThreeThenGotEight()
        {
            // Arange - подготовка данных
            const int Five  = 5;
            const int Three = 3;

            MathCalculator calculator = new MathCalculator();

            var result = calculator.Sum(5, 3);

            Assert.Equal(8, result);
        }
Exemplo n.º 21
0
        public void WhenSumFiveAndThreeThenGotEight()
        {
            //Arrange
            MathCalculator calculator = new MathCalculator();

            //Act
            var result1 = calculator.Sum(Five, Three);
            var result2 = calculator.Sub(Five, Three);

            //Assert
            Assert.Equal(Five + Three, result1);
        }
Exemplo n.º 22
0
        public void WhenSumFiveAndThreeThenGotEight()
        {
            MathCalculator calculator = new MathCalculator();

            //Act
            var r1 = calculator.Sum(3, 5);
            var r2 = calculator.Sub(5, 3);
            var r3 = calculator.Mul(5, 3);
            var r4 = calculator.Dev(5, 3);

            //Assert
            Assert.Equal(Five + Three, r1);
            Assert.Equal(Five - Three, r2);
            Assert.Equal(Five * Three, r3);
            Assert.Equal(Five / Three, r4);
        }