Update test code to run with multiprocess