Conversation
Prevents skipping legit files on Travis CI because `/build/` would also match `/home/travis/build/ampproject/amp-wp`
This was being used for QA last year but it has slowly discontinued being used. I'd rather see the automatic deploys be made to
We did have
You're right. Making Gutenberg a dependency was specifically to facilitate testing with AMP Stories. Once AMP Stories no longer requires Gutenberg to work (which may be the case as of 5.2 actually) then we should only install/activate Gutenberg on a single env.
We should also drop support for PHP<5.6 then as well.
Makes sense to me. |
Should be faster because of parallel jobs and fast finishing
|
Note: I was a bit surprised to see some of the tests pass. Turns out, wp-dev-lib downloads WP latest from https://develop.svn.wordpress.org/tags/5.2.1/, and In ba891ce I skipped the test if the theme is missing. |
What this PR does:
Travis already runs for PRs itself, running it again for the merge commit is usually pointless and just takes time.
This way, we don't bother running tests when code isn't properly formatted.
This way, the build will be marked as finished as soon as one job has failed. This is done under the assumption that all the other tests are likely to fail too when one has failed already.
ESLint is already run during the lint stage, and PHP syntax only needs to be tested once per PHP version.
Together with the fast finishing this makes things a bit faster in case of failures.
See screenshots below for comparison.
This job is allowed to fail
Before (link)
After (link)
Some thoughts/notes
npm run build:jsshould unnecessary for the linting stage and could probably be skipped there.ampconfdemodeploy stage still relevant?WP_VERSION=nightly.Changing that would be useful to catch potential conflicts early, and not just after WordPress has been released.
If I am not missing something, this never tests WordPress core's block editor integration as-is, but always uses the the Gutenberg one. Currently not much of a problem, as Gutenberg does not have any new PHP stuff at the moment. But when they're going to drop support for PHP < 5.6 this might cause problems in our tests.
Given that the PWA plugin only supports WordPress 5.2+, this should only be installed when testing WordPress 5.2+.
Fixes #2384.