testing: rewrite the test script with something less insane