public void BubbleSortDelegate_SortMinElementDescendArray_Axpected_ArgumentNullException() { int[][] inputArray = null; var comparer = new SortMinElementDescendArrayWithoutInterface(); Func <int[], int[], int> delegatInput = comparer.Compare; Assert.Throws <ArgumentNullException>(() => BubbleSortAcrossDelegate.BubbleSortDelegate(inputArray, delegatInput)); }
public void BubbleSortDelegate_SortMinElementDescendArray_With_Valid_Data() { var inputArray = HelperSort.GetJaggedArray(); var comparer = new SortMinElementDescendArrayWithoutInterface(); Func <int[], int[], int> delegatInput = comparer.Compare; BubbleSortAcrossDelegate.BubbleSortDelegate(inputArray, delegatInput); var outputMinElementRowArray = HelperSort.SortMinElementDescendHelper(inputArray).Item2; Assert.IsTrue(HelperSort.SortMinElementDescendHelper(inputArray).Item1); }