Skip to content

Commit 711ae59

Browse files
committed
Bump self-tests to 4.2 requirements (PHP 8.0 and PostgreSQL 13)
Note we also have applied a couple of extra changes: - Rename the both travis and gha job names to match. - Refactor travis noticeably to better separarte validate and integration tests, avoiding the "phantom" job that was caused by the matrix behaviour.
1 parent d041d7c commit 711ae59

File tree

2 files changed

+14
-14
lines changed

2 files changed

+14
-14
lines changed

.github/workflows/test.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,13 +26,13 @@ jobs:
2626
run: make validate
2727

2828
citest:
29-
name: CI test
29+
name: Integration tests
3030
needs: selftest
3131
runs-on: ubuntu-22.04
3232

3333
services:
3434
postgres:
35-
image: postgres:12
35+
image: postgres:13
3636
env:
3737
POSTGRES_USER: 'postgres'
3838
POSTGRES_HOST_AUTH_METHOD: 'trust'
@@ -45,7 +45,7 @@ jobs:
4545
fail-fast: false
4646
matrix:
4747
include:
48-
- php: '7.4'
48+
- php: '8.0'
4949
moodle-branch: 'master'
5050
- php: '7.4'
5151
moodle-branch: 'MOODLE_401_STABLE'
@@ -69,6 +69,7 @@ jobs:
6969
with:
7070
php-version: ${{ matrix.php }}
7171
extensions: pgsql, zip, gd, xmlrpc, soap
72+
ini-values: max_input_vars=5000
7273
# We want to verify that xdebug works for coverage. Once we only support
7374
# Moodle 3.10/PHPUnit 8 and up, we can switch our tests to pcov too.
7475
coverage: xdebug

.travis.yml

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
language: php
22

33
addons:
4-
postgresql: "12"
4+
postgresql: "13"
55
apt:
66
packages:
7-
- postgresql-12
8-
- postgresql-client-12
7+
- postgresql-13
8+
- postgresql-client-13
99

1010
services:
1111
- mysql
@@ -16,19 +16,16 @@ cache:
1616
- $HOME/.composer/cache
1717
- $HOME/.npm
1818

19-
php:
20-
- 7.4
21-
2219
env:
2320
global:
24-
- PGVER=12
21+
- PGVER=13
2522
- IGNORE_PATHS=ignore
2623
- IGNORE_NAMES=ignore_name.php
2724
- MUSTACHE_IGNORE_NAMES=broken.mustache
2825
- DB=pgsql
29-
- MOODLE_BRANCH=master
3026

3127
before_install:
28+
- echo 'max_input_vars=5000' >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini
3229
# We want to verify that xdebug works for coverage. Once we only support
3330
# Moodle 3.10/PHPUnit 8 and up, we can switch our tests to pcov too.
3431
# - phpenv config-rm xdebug.ini
@@ -49,8 +46,6 @@ install:
4946
- moodle-plugin-ci install -vvv
5047

5148
script:
52-
- make test-phpunit
53-
5449
# This is basically "integration" testing.
5550
- moodle-plugin-ci phplint
5651
- moodle-plugin-ci phpcpd
@@ -67,14 +62,18 @@ script:
6762

6863
jobs:
6964
include:
70-
- stage: Tests
65+
- stage: CI test (make validate)
7166
php: 7.3
7267
before_install: skip
7368
install:
7469
- make init
7570
script:
7671
- make validate
72+
7773
- stage: Integration tests
74+
if: env(MOODLE_BRANCH) IS present
75+
- php: 8.0
76+
env: MOODLE_BRANCH=master
7877
- php: 7.4
7978
env: MOODLE_BRANCH=MOODLE_401_STABLE
8079
- php: 7.4

0 commit comments

Comments
 (0)