Skip to content

Commit

Permalink
Bump highest php version to 8.0 for 311 and master
Browse files Browse the repository at this point in the history
Only real required change  is to set the new
max_input_vars=5000 requirement. Strictly speaking
only needed for php8, but it doesn't hurt with
older php versions and older moodle branches, so
setting it up always.

About the xmlrpc-beta extension, it's only needed
for php8 runs and only if the plugin uses xmlrpc
for something. If not, it can be omitted without
problem, as far as it's not a moodle requirement
but only a recommendation.
  • Loading branch information
stronk7 committed May 14, 2021
1 parent 5e596a5 commit 20b0f09
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 10 deletions.
23 changes: 19 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,18 +28,31 @@ jobs:
fail-fast: false
matrix:
include:
- php: 7.4
- php: 8.0
moodle-branch: master
database: pgsql
- php: 7.4
# The following line is only needed if you're going to run php8 jobs and your
# plugin needs xmlrpc services.
extensions: xmlrpc-beta
- php: 8.0
moodle-branch: master
database: mariadb
- php: 7.4
# The following line is only needed if you're going to run php8 jobs and your
# plugin needs xmlrpc services.
extensions: xmlrpc-beta
- php: 8.0
moodle-branch: MOODLE_311_STABLE
database: pgsql
- php: 7.4
# The following line is only needed if you're going to run php8 jobs and your
# plugin needs xmlrpc services.
extensions: xmlrpc-beta
- php: 8.0
moodle-branch: MOODLE_311_STABLE
database: mariadb
# The following line is only needed if you're going to run php8 jobs and your
# plugin needs xmlrpc services.
extensions: xmlrpc-beta

- php: 7.4
moodle-branch: MOODLE_310_STABLE
database: pgsql
Expand Down Expand Up @@ -88,6 +101,8 @@ jobs:
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: ${{ matrix.extensions }}
ini-values: max_input_vars=5000
coverage: none

- name: Initialise moodle-plugin-ci
Expand Down
18 changes: 12 additions & 6 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,15 @@ cache:

jobs:
include:
- php: 7.4
- php: 8.0
env: MOODLE_BRANCH=master DB=pgsql
- php: 7.4
- php: 8.0
env: MOODLE_BRANCH=master DB=mysqli
- php: 7.4
- php: 8.0
env: MOODLE_BRANCH=MOODLE_311_STABLE DB=pgsql
- php: 7.4
- php: 8.0
env: MOODLE_BRANCH=MOODLE_311_STABLE DB=mysqli

- php: 7.4
env: MOODLE_BRANCH=MOODLE_310_STABLE DB=pgsql
- php: 7.4
Expand Down Expand Up @@ -60,6 +61,10 @@ jobs:
# be executed with that PHP versions.

before_install:
# The following line is only needed if you're going to run php8 jobs and your
# plugin needs xmlrpc services.
- if [[ ${TRAVIS_PHP_VERSION:0:1} -gt 7 ]]; then pecl install xmlrpc-beta; fi
- echo 'max_input_vars=5000' >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini
- phpenv config-rm xdebug.ini
- cd ../..
- composer create-project -n --no-dev --prefer-dist moodlehq/moodle-plugin-ci ci ^3
Expand All @@ -74,17 +79,18 @@ before_install:
fi
install:
- moodle-plugin-ci install
# Quiet to avoid moodle-plugin-ci detecting some behat PHP warnings. Remove it once MDL-71622 is sorted out.
- moodle-plugin-ci install --quiet

script:
- moodle-plugin-ci phplint
- moodle-plugin-ci phpcpd
- moodle-plugin-ci phpmd
- moodle-plugin-ci codechecker
- moodle-plugin-ci phpdoc
- moodle-plugin-ci validate
- moodle-plugin-ci savepoints
- moodle-plugin-ci mustache
- moodle-plugin-ci grunt
- moodle-plugin-ci phpdoc
- moodle-plugin-ci phpunit
- moodle-plugin-ci behat

0 comments on commit 20b0f09

Please sign in to comment.