Ejemplo n.º 1
0
        public void One_Number_Sum(string numbers)
        {
            var task = new StringCalculatorGenerator();

            char[] delimeters  = { ',' };
            var    expectedSum = 1;

            Assert.Equal(expectedSum, task.AddNumbers(numbers, delimeters));
        }
Ejemplo n.º 2
0
        public void MultipleDelimeters_Numbers_Sum(string numbers)
        {
            var task = new StringCalculatorGenerator();

            char[] delimeters  = { '/', '*', '-', ',' };
            var    expectedSum = 15;

            Assert.Equal(expectedSum, task.AddNumbers(numbers, delimeters));
        }