예제 #1
0
        public void AddWithDelimiters()
        {
            kalbasi kalbasiAdd = new kalbasi();
            var     result     = kalbasiAdd.Add("//;\n1;2");

            Assert.AreEqual(result, 3);
        }
예제 #2
0
        public void AddWithNewLine()
        {
            kalbasi kalbasiAdd = new kalbasi();
            var     result     = kalbasiAdd.Add("1\n2,1000");

            Assert.AreEqual(result, 1003);
        }
예제 #3
0
        public void AddWithMoreThanTwoNumbersInString()
        {
            kalbasi kalbasiAdd = new kalbasi();
            var     result     = kalbasiAdd.Add("1,2,123,1000");

            Assert.AreEqual(result, 1126);
        }
예제 #4
0
        public void AddWithTwoNumberInString()
        {
            kalbasi kalbasiAdd = new kalbasi();
            var     result     = kalbasiAdd.Add("1,2");

            Assert.AreEqual(result, 3);
        }
예제 #5
0
 public void AddWithNegativeNumbers()
 {
     kalbasi kalbasiAdd = new kalbasi();
     var     result     = kalbasiAdd.Add("-1,2,-3");
 }
예제 #6
0
 public void AddWithNewLineWithErorr()
 {
     kalbasi kalbasiAdd = new kalbasi();
     var     result     = kalbasiAdd.Add("1,\n");
 }