Skip to content

Commit 99042de

Browse files
jrchampstronk7
authored andcommitted
ci examples: clarify code coverage comments
1 parent 3305009 commit 99042de

File tree

4 files changed

+11
-5
lines changed

4 files changed

+11
-5
lines changed

.travis.dist.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,10 @@ env:
3434
before_install:
3535
- if [[ ${TRAVIS_PHP_VERSION:0:1} -gt 7 ]]; then pecl install xmlrpc-beta; fi
3636
- echo 'max_input_vars=5000' >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini
37-
# Don't disable xdebug if you want to get it used for code coverage.
37+
# We remove xdebug by default for performance, because we're not checking code coverage.
38+
# If you want to use xdebug for code coverage, remove this line.
3839
- phpenv config-rm xdebug.ini
39-
# Alternative (for Moodle 3.10 and up) is to use pcov. It can be installed using:
40+
# To use pcov for code coverage on Moodle 3.10 and up, install it using:
4041
# - pecl install pcov
4142
- cd ../..
4243
- composer create-project -n --no-dev --prefer-dist moodlehq/moodle-plugin-ci ci ^3

docs/GHAFileExplained.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,8 @@ jobs:
9595
php-version: ${{ matrix.php }}
9696
extensions: ${{ matrix.extensions }}
9797
ini-values: max_input_vars=5000
98-
# none to use phpdbg fallback. Specify pcov (Moodle 3.10 and up) or xdebug to use them instead.
98+
# If you are not using code coverage, keep "none". Otherwise, use "pcov" (Moodle 3.10 and up) or "xdebug".
99+
# If you try to use code coverage with "none", it will fallback to phpdbg (which has known problems).
99100
coverage: none
100101

101102
# Install this project into a directory called "ci", updating PATH and

docs/TravisFileExplained.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,8 +89,11 @@ before_install:
8989
- if [[ ${TRAVIS_PHP_VERSION:0:1} -gt 7 ]]; then pecl install xmlrpc-beta; fi
9090
# Setup a good default max_input_vars value for all runs.
9191
- echo 'max_input_vars=5000' >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini
92-
# This disables XDebug which should speed up the build.
92+
# We remove xdebug by default for performance, because we're not checking code coverage.
93+
# If you want to use xdebug for code coverage, remove this line.
9394
- phpenv config-rm xdebug.ini
95+
# To use pcov for code coverage on Moodle 3.10 and up, install it using:
96+
# - pecl install pcov
9497
# Currently we are inside of the clone of your repository. We move up two
9598
# directories to build the project.
9699
- cd ../..

gha.dist.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,8 @@ jobs:
4646
php-version: ${{ matrix.php }}
4747
extensions: ${{ matrix.extensions }}
4848
ini-values: max_input_vars=5000
49-
# none to use phpdbg fallback. Specify pcov (Moodle 3.10 and up) or xdebug to use them instead.
49+
# If you are not using code coverage, keep "none". Otherwise, use "pcov" (Moodle 3.10 and up) or "xdebug".
50+
# If you try to use code coverage with "none", it will fallback to phpdbg (which has known problems).
5051
coverage: none
5152

5253
- name: Initialise moodle-plugin-ci

0 commit comments

Comments
 (0)