public void SortArrayUsingMergeSortTest(int[] initial, int[] expected) { // Arrange SortingClass class1 = new SortingClass(); // Act int[] actual = class1.MergeSort(initial); // Assert Assert.AreEqual(expected, actual); }
public void EmptyArrayMergeSortTest() { SortingClass class1 = new SortingClass(); Assert.Throws <ArgumentException>(() => class1.MergeSort(new int[] { })); }
public void NullArgumentMergeSortTest() { SortingClass class1 = new SortingClass(); Assert.Throws <ArgumentNullException>(() => class1.MergeSort(null)); }