Assert.assertArrayEquals(new int[]{1, 2, 2, 3, 5, 5, 6, 8, 9, 34}, dispatcher.sort());
}
@Test
public void testDispatcherNormal3Threads() throws InterruptedException, ExecutionException, IOException {
Dispatcher dispatcher = new Dispatcher("multicoreTest.txt", 3);
Assert.assertArrayEquals(new int[]{1, 2, 2, 3, 5, 5, 6, 8, 9, 34}, dispatcher.sort());
dispatcher = new Dispatcher("multicoreTest_1_by_1.txt", 3);
Assert.assertArrayEquals(new int[]{1, 2, 2, 3, 5, 5, 6, 8, 9, 34}, dispatcher.sort());
}