Add queue.finish() calls to test_inplace_reduce

This adds calls to queue.finish() to ensure that the results
are ready before being checked in the inplace_reduce test.
Add queue.finish() calls to test_merge

This adds calls to queue.finish() to ensure that the results
are ready before being checked in the merge test.
Add queue.finish() call to test_mersenne_twister

This adds a call to queue.finish() to ensure that the results
are ready before being checked in the mersenne_twister test.