### Question:
Sort { public int[] sort(int[] m) { if (m.length <= 1) return m; int middle = m.length / 2; int[] left = Arrays.copyOf(m,middle); int[] right = Arrays.copyOfRange(m,middle,m.length); right = sort(right); left = sort(left); int[] result = merge(left, right); return result; }  int[] sort(int[] m); int[] merge(int[] left, int[] right);  }### Answer:
@Test(timeout=1000) public void randomArrayTest() { for (int i = 0; i < 100; i++) { int[] random = getRandomArray(new Random().nextInt(200)+1); assertArrayEquals(sort(random), new Sort().sort(random)); } }
@Test(timeout=1000) public void sortArrayTest() { for (int i = 0; i < 50; i++) { int[] random = getSortArray(new Random().nextInt(200)+1); assertArrayEquals(random, new Sort().sort(random)); } }
@Test(timeout=1000) public void reverseArrayTest() { for (int i = 0; i < 50; i++) { int[] random = getReverseArray(new Random().nextInt(200)+1); assertArrayEquals(sort(random), new Sort().sort(random)); } }
@Test(timeout=1000) public void equalArrayTest() { for (int i = 0; i < 50; i++) { int[] random = getEqualArray(new Random().nextInt(200)+1); assertArrayEquals(sort(random), new Sort().sort(random)); } }
@Test(timeout=1000) public void emptyArrayTest() { int[] random = new int[0]; assertArrayEquals(sort(random), new Sort().sort(random)); }