phantomas.runScript: wait until it's finished

Fixes #417
Merge pull request #434 from macbre/wait-for-run-script-to-complete

phantomas.runScript: wait until it's finished