@Test
public void testParallelPartitionScaleDown()
{

  DummyOperator dummyOperator = new DummyOperator(5);
  StatelessPartitioner<DummyOperator> statelessPartitioner = new StatelessPartitioner<>();
  Collection<Partition<DummyOperator>> partitions = Lists.newArrayList();
  for (int i = 5; i-- > 0; ) {
    partitions.add(new DefaultPartition<>(dummyOperator));
  }
  Collection<Partition<DummyOperator>> newPartitions = statelessPartitioner.definePartitions(partitions,
      new PartitioningContextImpl(null, 1));
  Assert.assertEquals("after partition", 1, newPartitions.size());
}