|
1 |
| -name: Moodle plugin CI for master |
| 1 | +name: Run all tests for moodle 35 to 39 |
2 | 2 |
|
3 | 3 | on: [push, pull_request]
|
4 | 4 |
|
5 | 5 | jobs:
|
6 |
| - setup: |
7 |
| - name: CI test |
8 |
| - env: |
9 |
| - IGNORE_PATHS: tests/fixtures |
10 |
| - runs-on: 'ubuntu-latest' |
11 |
| - |
12 |
| - services: |
13 |
| - postgres: |
14 |
| - image: postgres:9.6 |
15 |
| - env: |
16 |
| - POSTGRES_USER: 'postgres' |
17 |
| - POSTGRES_HOST_AUTH_METHOD: 'trust' |
18 |
| - options: >- |
19 |
| - --health-cmd pg_isready |
20 |
| - --health-interval 10s |
21 |
| - --health-timeout 5s |
22 |
| - --health-retries 3 |
23 |
| - ports: |
24 |
| - - 5432:5432 |
25 |
| - |
26 |
| - mariadb: |
27 |
| - image: mariadb:10.5 |
28 |
| - env: |
29 |
| - MYSQL_USER: 'root' |
30 |
| - MYSQL_ALLOW_EMPTY_PASSWORD: "true" |
31 |
| - ports: |
32 |
| - - 3306:3306 |
33 |
| - options: >- |
34 |
| - --health-cmd="mysqladmin ping" |
35 |
| - --health-interval 10s |
36 |
| - --health-timeout 5s |
37 |
| - --health-retries 3 |
38 |
| - strategy: |
39 |
| - fail-fast: false |
40 |
| - matrix: |
41 |
| - database: ['mariadb', 'pgsql'] |
42 |
| - moodle-branch: [ |
43 |
| - 'MOODLE_35_STABLE', |
44 |
| - 'MOODLE_36_STABLE', |
45 |
| - 'MOODLE_37_STABLE', |
46 |
| - 'MOODLE_38_STABLE', |
47 |
| - 'MOODLE_39_STABLE', |
48 |
| - ] |
49 |
| - node: ['14.15'] |
50 |
| - php: ['7.1', '7.2', '7.3'] |
51 |
| - exclude: |
52 |
| - - moodle-branch: MOODLE_35_STABLE |
53 |
| - php: 7.3 |
54 |
| - - moodle-branch: MOODLE_39_STABLE |
55 |
| - php: 7.1 |
56 |
| - |
57 |
| - steps: |
58 |
| - - name: Check out repository code |
59 |
| - uses: actions/checkout@v2 |
60 |
| - with: |
61 |
| - path: plugin |
62 |
| - |
63 |
| - - name: Install node ${{ matrix.node }} |
64 |
| - uses: actions/setup-node@v2 |
65 |
| - with: |
66 |
| - node-version: ${{ matrix.node }} |
67 |
| - |
68 |
| - - name: Setup PHP ${{ matrix.php }} |
69 |
| - uses: shivammathur/setup-php@v2 |
70 |
| - with: |
71 |
| - php-version: ${{ matrix.php }} |
72 |
| - extensions: pgsql, mysqli, zip, gd, xmlrpc, soap |
73 |
| - coverage: none |
74 |
| - |
75 |
| - - name: Initialise moodle-plugin-ci |
76 |
| - run: | |
77 |
| - composer create-project -n --no-dev --prefer-dist moodlehq/moodle-plugin-ci ci ^3 |
78 |
| - # Add dirs to $PATH |
79 |
| - echo $(cd ci/bin; pwd) >> $GITHUB_PATH |
80 |
| - echo $(cd ci/vendor/bin; pwd) >> $GITHUB_PATH |
81 |
| - # PHPUnit depends on en_AU.UTF-8 locale |
82 |
| - sudo locale-gen en_AU.UTF-8 |
83 |
| -
|
84 |
| - - name: Install local_aws |
85 |
| - if: ${{ always() }} |
86 |
| - run: moodle-plugin-ci add-plugin catalyst/moodle-local_aws |
87 |
| - |
88 |
| - - name: Install Moodle |
89 |
| - run: moodle-plugin-ci install -vvv --plugin ./plugin --db-host=127.0.0.1 |
90 |
| - env: |
91 |
| - DB: ${{ matrix.database }} |
92 |
| - MOODLE_BRANCH: ${{ matrix.moodle-branch }} |
93 |
| - |
94 |
| - - name: Run phplint |
95 |
| - if: ${{ always() }} |
96 |
| - run: moodle-plugin-ci phplint |
97 |
| - |
98 |
| - - name: Run codechecker |
99 |
| - if: ${{ always() }} |
100 |
| - run: moodle-plugin-ci codechecker |
101 |
| - |
102 |
| - - name: Run validate |
103 |
| - if: ${{ always() }} |
104 |
| - run: moodle-plugin-ci validate |
105 |
| - |
106 |
| - - name: Run savepoints |
107 |
| - if: ${{ always() }} |
108 |
| - run: moodle-plugin-ci savepoints |
109 |
| - |
110 |
| - - name: Run mustache |
111 |
| - continue-on-error: true # This step will show errors but will not fail |
112 |
| - if: ${{ always() }} |
113 |
| - run: moodle-plugin-ci mustache |
114 |
| - |
115 |
| - - name: Run phpunit |
116 |
| - if: ${{ always() }} |
117 |
| - run: moodle-plugin-ci phpunit |
118 |
| - |
119 |
| - - name: Run behat |
120 |
| - if: ${{ always() }} |
121 |
| - run: moodle-plugin-ci behat --profile chrome |
122 |
| - |
123 |
| - - name: PHP Copy/Paste Detector |
124 |
| - continue-on-error: true # This step will show errors but will not fail |
125 |
| - if: ${{ always() }} |
126 |
| - run: moodle-plugin-ci phpcpd |
127 |
| - |
128 |
| - - name: PHP Mess Detector |
129 |
| - continue-on-error: true # This step will show errors but will not fail |
130 |
| - if: ${{ always() }} |
131 |
| - run: moodle-plugin-ci phpmd |
| 6 | + workflow_group_35_to_39_ci: |
| 7 | + uses: catalyst/catalyst-moodle-workflows/.github/workflows/group-35-to-39-ci.yml@main |
| 8 | + with: |
| 9 | + extra_plugin_runners: 'moodle-plugin-ci add-plugin catalyst/moodle-local_aws' |
| 10 | + disable_grunt: true |
0 commit comments