Rewrite reduce_by_key test

So that VS2010 is able to compile it in Debug mode