refactor master and worker into seperate files
test success/fail message