Map reduce

Make this an innerclass of the test. I'm very concerned about this 'helpers'.