rewrite tests/run.sh