@Test
public void testProcessStatsForPartitionCount()
{

  TestUtils.MockBatchedOperatorStats readerStats = new TestUtils.MockBatchedOperatorStats(2);
  readerStats.operatorStats = Lists.newArrayList();
  readerStats.operatorStats.add(new ReaderStats(10, 1, 100, 1));
  TestReader sliceReader = new TestReader();
  StatsListener.Response response = sliceReader.processStats(readerStats);
  Assert.assertTrue("partition needed", response.repartitionRequired);
  Assert.assertEquals("partition count changed", 8, sliceReader.getPartitionCount());
}