Skip to content

Commit 9ed44bc

Browse files
committed
Merge branch 'master' into moodle_50_only_load_sections_on_page
2 parents 19a225e + 1170d15 commit 9ed44bc

71 files changed

Lines changed: 2332 additions & 2317 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/moodle-ci.yml

Lines changed: 12 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ jobs:
1111

1212
services:
1313
postgres:
14-
image: postgres:13 # Moodle 4.2: >=13
14+
image: postgres:15 # Moodle 5.1
1515
env:
1616
POSTGRES_USER: 'postgres'
1717
POSTGRES_HOST_AUTH_METHOD: 'trust'
@@ -20,7 +20,7 @@ jobs:
2020
options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 3
2121

2222
mariadb:
23-
image: mariadb:10.6 # Moodle 4.2 >=10.6.7
23+
image: mariadb:10.11 # Moodle 5.0
2424
env:
2525
MYSQL_USER: 'root'
2626
MYSQL_ALLOW_EMPTY_PASSWORD: "true"
@@ -35,42 +35,20 @@ jobs:
3535
fail-fast: false
3636
matrix:
3737
include:
38-
# Moodle 4.0, PHP 7.3, PostgreSQL
39-
- php: '7.3' # 7.3-8.0
40-
moodle-branch: 'MOODLE_400_STABLE'
38+
# Moodle 5.0, PHP 8.2, PostgreSQL
39+
- php: '8.2' # 8.2-8.4
40+
moodle-branch: 'MOODLE_500_STABLE'
4141
database: pgsql
42-
plugin-ci: ^3
43-
# Moodle 4.1, PHP 7.4, MariaDB
44-
- php: '7.4' # 7.4-8.1
45-
moodle-branch: 'MOODLE_401_STABLE'
46-
database: mariadb
47-
plugin-ci: ^3
48-
# Moodle 4.2, PHP 8.0, PostgreSQL
49-
- php: '8.0' # 8.0-8.2
50-
moodle-branch: 'MOODLE_402_STABLE'
51-
database: pgsql
52-
plugin-ci: ^4
53-
# extensions: xmlrpc-beta
54-
# Moodle 4.3, PHP 8.1, MariaDB
55-
- php: '8.1' # 8.0-8.2
56-
moodle-branch: 'MOODLE_403_STABLE'
57-
database: mariadb
5842
plugin-ci: ^4
5943
# extensions: xmlrpc-beta
60-
# Moodle 4.4, PHP 8.2, PostgreSQL
61-
- php: '8.2' # 8.1-8.3
62-
moodle-branch: 'MOODLE_404_STABLE'
63-
database: pgsql
64-
plugin-ci: ^4
65-
# extensions: xmlrpc-beta
66-
# Moodle 4.5, PHP 8.3, MariaDB
67-
- php: '8.3'
68-
moodle-branch: 'MOODLE_405_STABLE'
44+
# Moodle 5.1, PHP 8.3, MariaDB
45+
- php: '8.3' # 8.2-8.4
46+
moodle-branch: 'main'
6947
database: mariadb
7048
plugin-ci: ^4
7149
# extensions: xmlrpc-beta
72-
# Moodle main, PHP 8.3, PostgreSQL
73-
- php: '8.3'
50+
# Moodle 5.1, PHP 8.4, PostgresSQL
51+
- php: '8.4' # 8.2-8.4
7452
moodle-branch: 'main'
7553
database: pgsql
7654
plugin-ci: ^4
@@ -128,7 +106,7 @@ jobs:
128106

129107
- name: Moodle PHPDoc Checker
130108
if: ${{ !cancelled() }}
131-
run: moodle-plugin-ci phpdoc
109+
run: moodle-plugin-ci phpdoc --max-warnings 0
132110

133111
- name: Validating
134112
if: ${{ !cancelled() }}
@@ -153,7 +131,7 @@ jobs:
153131
- name: Behat features
154132
id: behat
155133
if: ${{ !cancelled() }}
156-
run: moodle-plugin-ci behat --profile chrome
134+
run: moodle-plugin-ci behat --profile chrome --scss-deprecations
157135

158136
- name: Upload Behat Faildump
159137
if: ${{ failure() && steps.behat.outcome == 'failure' }}

_course_changenumsections.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,10 +29,10 @@
2929
* @since Moodle 2.3
3030
*/
3131

32+
use core_courseformat\formatactions; // ADDED.
33+
3234
require_once(__DIR__.'/../../../config.php'); // CHANGED.
3335
require_once($CFG->dirroot.'/course/lib.php');
34-
require_once(__DIR__.'/locallib.php');
35-
// ADDED LINE ABOVE: For function format_multitopic_course_create_section .
3636

3737
$courseid = required_param('courseid', PARAM_INT);
3838
$increase = optional_param('increase', null, PARAM_BOOL);
@@ -114,7 +114,7 @@
114114
}
115115
$sections = [];
116116
for ($i = 0; $i < max($numsections, 1); $i ++) {
117-
$sections[] = format_multitopic_course_create_section($course, $insertsection);
117+
$sections[] = formatactions::section($course)->fmt_create_from_object($insertsection);
118118
// CHANGED LINE ABOVE: Use custom method, and send section info, not section number.
119119
}
120120
$returnurl = course_get_url($course, $sections[0], []);

_course_editsection.php

Lines changed: 0 additions & 177 deletions
This file was deleted.

0 commit comments

Comments
 (0)