-
Notifications
You must be signed in to change notification settings - Fork 1
Permalink
Choose a base ref
{{ refName }}
default
Choose a head ref
{{ refName }}
default
Comparing changes
Choose two branches to see what’s changed or to start a new pull request.
If you need to, you can also or
learn more about diff comparisons.
Open a pull request
Create a new pull request by comparing changes across two branches. If you need to, you can also .
Learn more about diff comparisons here.
base repository: pantheon-systems/wpunit-helpers
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v1.0.1
Could not load branches
Nothing to show
Loading
Could not load tags
Nothing to show
{{ refName }}
default
Loading
...
head repository: pantheon-systems/wpunit-helpers
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v2.0.0
Could not load branches
Nothing to show
Loading
Could not load tags
Nothing to show
{{ refName }}
default
Loading
- 1 commit
- 13 files changed
- 2 contributors
Commits on Feb 13, 2024
-
[major] Refactor WP install scripts to use WP-CLI (#3)
* add helpers.sh to provide functions to other scripts * add composer diff * address shellcheck feedback * use our helpers and tweak the local test install * remove functions sourced in helpers * tweak the test script and run against nightly on single and multisite * test for helpers, too * output wp version * update download function * remove extra linebreak * add a comment * fix grep * remove comment * bump checkout to v4 * turn debugging on so we can debug this in the mu-plugin * allow a version to be passed to install-local-tests * add a download wp function * add a setup_wp function * remove set -e since this will only be sourced * fix spacing * remove the install_wp function replacing with our own using wpcli * setup_wp_nightly uses setup_wp * install_db needs some params * add a cleanup * also reset the db in the cleanup * default to no db pass for local install * Refactor install-wp-tests.sh script * use phpunit instead of test for consistency * use flags instead of args * check if the json file exists before removing it * use --version * allow tmpdir to be passed, too * remove the question * fix spacing * update usage * set SKIP_DB to the value we pass along to install-wp-tests * fix the syntax * fix the syntax * shellcheck all the things * add an empty phpunit script this lets us run the tests ourselves in the future we could add some files to run tests on but for now this doesn't do anything * run through the scripts * remove unused var * fix the passed args * there's no skip_db in this function * turn on debugging * set the tmpdir to install into * change the test name * be more specific about the phpunit test * fix the skip db bit * install wp-cli * fix wp-cli install * echo where we're installing WordPress * add the rest of the vars to the install script * turn debugging on for the install wp script, too * pass all the params to setup_wp * create the database before installing wp * debug helpers * match the order to what we're passing * echo what we're doing with the database * fix the conditional to install the db * actually add a database to connect to * try the test without a db pass * fix db pass in install_db function * we actually want word splitting here * add root password back * some tests to mysql to make sure it's running and we have the right un/pw * move the shellcheck ignore * we actually do need to get the version from the json file * pass the wp version into install_test_suite * use flags for wp version and tmp dir * we need to also pass the tmpdir * we also need wp tests dir and db info in install_test_suite * pass those values in * fix the paths * remove debugging * print the working directory wanna see where we are so we know where to run composer script from * don't cd into the test directory * bash the script * can we set the shell to bash and remove the bash command? * give the robot permission to read * switch back * turn on debugging for nightly test * remove the shifts * remove unused usage function * remove all shifts * remove moar shifts * debug the actual command * replace --no-db with --skip-db * add right param to composer includes * echo the passed args for debugging * move the passed args debugging line higher so we can see it for both runs * move local tests to a script * remove the bash * run chmod in the script * add permissions * bail if the script doesn't exist * change the shebang in all the things * handle line ending conversions appropriately * ls the bin folder after the chmod and chmod the right thing * don't bash the script * ignore problemmatic things * remove quotes * force the wp download * don't create the wp-config if it exists * remove debug code and cleanup when the test is done * move setup stuff to the top * cleanup on the right thing * add db values as env variables to reset the db * drop the database * remove debug code * move test file validation to a script * add comments to helpers * [major] Update readme * shellcheck the test scripts, too * fix nightly setup needs to mirror setup_wp because we pass the same parameters along * run the nightly install if that's what was requested * remove passed args debug code * remove setup_wp_nightly in phpunit-test.sh it's run in install-wp-tests.sh * remove gitattributes we probably don't need it * remove debug Co-authored-by: Phil Tyler <[email protected]> * fix dumb comment thing Co-authored-by: Phil Tyler <[email protected]> * add missing : Co-authored-by: Phil Tyler <[email protected]> * loop over the files to check * set variables to local so we don't run into global clashes * make the file check test a loop * use string manipulation instead of parsing the string parts before/after the colon * better handling of EXTRA using an array * add to the EXTRA array rather than overwriting it * apply the same logic to bash wp install args * allow variables to be overridden with env variables * remove local * add some logging not sure where things are failing exactly * turn on debugging so we can see what values were passed in * remove defaults * move debugging to install_db step * revert string manipulation * move the debugging * remove debugging * remove --version from SETUP_ARGS it's only needed for non-nightly runs * remove test in loop Co-authored-by: Phil Tyler <[email protected]> * wrap install-local-tests and install-wp-tests in a function * use local variables in all helper functions * let's put the phpunit-test script in a function, too we don't need to pass args into it because we don't pass args into the script * fix local DIRNAME for shellcheck --------- Co-authored-by: Phil Tyler <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 8f77f20 - Browse repository at this point
Copy the full SHA 8f77f20View commit details
Loading
This comparison is taking too long to generate.
Unfortunately it looks like we can’t render this comparison for you right now. It might be too big, or there might be something weird with your repository.
You can try running this command locally to see the comparison on your machine:
git diff v1.0.1...v2.0.0