Example #1
0
        public void FindIndexMaxElement_WhenArrayPassed_ShouldResult(int mockNumber, int expected)
        {
            int[] arr    = ArrayTests.GetArrayMock(mockNumber);
            int   actual = Array.FindIndexMaxElement(arr);

            Assert.AreEqual(expected, actual);
        }
Example #2
0
        public void GetCountOfOddElements_WhenArrayPassed_ShouldResult(int mockNumber, int expected)
        {
            int[] arr    = ArrayTests.GetArrayMock(mockNumber);
            int   actual = Array.GetCountOfOddElements(arr);

            Assert.AreEqual(expected, actual);
        }
Example #3
0
        public void SummElemWithOddIndex_WhenArrayPassed_ShouldResult(int mockNumber, int expected)
        {
            int[] arr    = ArrayTests.GetArrayMock(mockNumber);
            int   actual = Array.SummElemWithOddIndex(arr);

            Assert.AreEqual(expected, actual);
        }
Example #4
0
 public void GetSwapedHalves_WhenArrayPassed_ShouldResult(int mockNumber, int[] expected)
 {
     int[] arr    = ArrayTests.GetArrayMock(mockNumber);
     int[] actual = Array.GetSwapedHalves(arr);
     Assert.AreEqual(expected, actual);
 }