Пример #1
0
        public void SearchNumbersWithEmptyResult()
        {
            var result = NumbersFunctions.SearchNumbers(30, 2);

            Assert.AreEqual(expected: new int[] { }, result);
        }
Пример #2
0
        public void SearchNumbersWithOneResult()
        {
            var result = NumbersFunctions.SearchNumbers(1, 2);

            Assert.AreEqual(expected: new int[] { 1, 10, 10 }, result);
        }
Пример #3
0
 public void InvalidSumParam()
 {
     Assert.Throws <ArgumentException>(() => NumbersFunctions.SearchNumbers(-10, 10));
 }
Пример #4
0
        public void ValidParam()
        {
            var result = NumbersFunctions.SearchNumbers(6, 3);

            Assert.AreEqual(expected: new int[] { 21, 105, 600 }, result);
        }
Пример #5
0
 public void InvalidCapacityParam()
 {
     Assert.Throws <ArgumentException>(() => NumbersFunctions.SearchNumbers(10, -1));
 }