Exemple #1
0
 public void CheckQuickSortOnEmpty() => Assert.Throws <ArgumentException>(() => SortingMethods.Quicksort(new int[] { }));
Exemple #2
0
 public void QuickSortTest()
 {
     int[] array = { 24, 16, 54, -4, 3, 47, 93, 101, 255, -34, -2019 };
     SortingMethods.Quicksort(array);
     Assert.AreEqual(new int[] { -2019, -34, -4, 3, 16, 24, 47, 54, 93, 101, 255 }, array);
 }
Exemple #3
0
 public void CheckQuickSortOnNull() => Assert.Throws <ArgumentNullException>(() => SortingMethods.Quicksort(null));