scaffold plugin-tests: create install-wp-tests.sh script

Writing all that bash code in `.yml` always felt awkward. But the most annoying part is that you couldn't test the build script locally.

So, let's just move the bulk of the code to a separate file.

We've adopted this strategy for WP-CLI itself: f121dfac28e9268f55a03f911e8c2f366441ec46