diff --git a/app/src/main/java/de/uni_marburg/powersort/data/DataEnum.java b/app/src/main/java/de/uni_marburg/powersort/data/DataEnum.java index d375b5e..7c8a783 100644 --- a/app/src/main/java/de/uni_marburg/powersort/data/DataEnum.java +++ b/app/src/main/java/de/uni_marburg/powersort/data/DataEnum.java @@ -14,8 +14,8 @@ public enum DataEnum { int longListSize = 300_000_000; // Any larger: Out of Heap Space. TODO GRADLE config int middleListSize = 250_000_000; - int runs = 1000; - int runLength = 1000; + int runs = 1_000; + int runLength = 1_000; return switch (this) { case RANDOM_INTEGERS_300M -> new RandomIntegers(longListSize, seed); diff --git a/app/src/main/java/de/uni_marburg/powersort/sort/SortEnum.java b/app/src/main/java/de/uni_marburg/powersort/sort/SortEnum.java index 8053d53..0ceb21a 100644 --- a/app/src/main/java/de/uni_marburg/powersort/sort/SortEnum.java +++ b/app/src/main/java/de/uni_marburg/powersort/sort/SortEnum.java @@ -4,16 +4,16 @@ import de.uni_marburg.powersort.FinnSort.FinnSort; import de.uni_marburg.powersort.benchmark.NaturalOrder; public enum SortEnum { -// BUBBLE_SORT, -// MERGE_SORT, + BUBBLE_SORT, + MERGE_SORT, TIM_SORT, FINN_SORT, ASORT; public SortImpl getSortImpl() { return switch (this) { -// case BUBBLE_SORT -> array -> BubbleSort.sort(array, NaturalOrder.INSTANCE); -// case MERGE_SORT -> array -> MergeSort.legacyMergeSort(array, NaturalOrder.INSTANCE); + case BUBBLE_SORT -> array -> BubbleSort.sort(array, NaturalOrder.INSTANCE); + case MERGE_SORT -> array -> MergeSort.legacyMergeSort(array, NaturalOrder.INSTANCE); case TIM_SORT -> array -> TimSort.sort(array, 0, array.length, NaturalOrder.INSTANCE, null, 0, 0); case FINN_SORT -> array -> FinnSort.sort(array, NaturalOrder.INSTANCE); case ASORT -> array -> ASort.sort(array, NaturalOrder.INSTANCE); diff --git a/app/src/test/java/de/uni_marburg/powersort/sort/BubbleSortTest.java b/app/src/test/java/de/uni_marburg/powersort/sort/BubbleSortTest.java new file mode 100644 index 0000000..65d5fbc --- /dev/null +++ b/app/src/test/java/de/uni_marburg/powersort/sort/BubbleSortTest.java @@ -0,0 +1,7 @@ +package de.uni_marburg.powersort.sort; + +public class BubbleSortTest extends AbstractSortTest { + BubbleSortTest() { + sortAlg = SortEnum.BUBBLE_SORT; + } +}