forked from Wunderbyte-GmbH/moodle-mod_newsletter
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
executable file
·107 lines (97 loc) · 5.89 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
# This is the language of our project.
language: php
# This tells Travis CI to use its new architecture. Everything is better!
sudo: false
dist: trusty
# This tells Travis CI to cache Composer's cache. Speeds up build times.
cache:
directories:
- $HOME/.composer/cache
services:
- mysql
# Determines which versions of PHP to test our project against. Each version listed
# here will create a separate build and run the tests against that version of PHP.
# WARNING, PHP7 only works in Moodle 3.0.1 or later!
php:
- 7.0
# This section sets up the environment variables for the build.
env:
global:
# This line determines which version of Moodle to test against.
- IGNORE_PATHS=lib/,CssToInlineStyles/,classes/bounce/bounceprocessor.php,module.js,toc.css,styles.css
# This matrix is used for testing against multiple databases. So for each version of
# PHP being tested, one build will be created for each database listed here. EG: for
# PHP 5.4, one build will be created using PHP 5.4 and pgsql. In addition, another
# build will be created using PHP 5.4 and mysqli.
matrix:
- DB=mysqli MOODLE_BRANCH=MOODLE_35_STABLE
# This section defines who's going to receive the notifications!
notifications:
email:
# right now, we use the automatic recipients list, in the future we could specify them like below
#recipients:
# - secure: "wvrbHUFW97rRKj6LOPj3qWdwBjQFrXtczU3TFd3f48aDOeN3qxKOA3Ycuj3HnpHOvq+EEUeVIjubhAvQfJgiJ2n8/PORdtTU2ARTAUx9z/c8ik5jXTpMXcwEDSSTHhhqKABpzun4qLoqAaBdkqb0jTaNQOfPr9hRoRsTXi07jMNBUsKB0dSy4W8CiGNB93r8uZRIBo2ZlKbZoVbA9EMJQO+wXYuabBiV8mLD7R/qTxBX5qix/gHnKKnDnbwtfUBMVu/XhJihP0aGznQF2xG5PiWaTXPWayv+VIm4Ryx+3cQhOqZmyIRaZvR6Ukvyd16ijrNm+BwaCVJGoaHwOr1YYp+3wY6vV/cyJFMU4Ome+wIyJKjEWa5ZkEfXda8Shs/PmSZEN9Wi5y145SSXe/n3hv/1qWj7t3sD8FsbAsH5I5yNkVUcAYkmZjWqR4kTMlL2tVqSXck71nVRZ9PS0x1bXrX84WNaPMJk4eCeAvVhmtYHviZaGVe++hDAn4aDKi3rf/fB7xhwQhx3k6NpRQfmr6EaYf6E6CllRwUWYb65D/KM7lQt7chrgQryT65CqI6/DqHA9ZdG2iwRIiKlRavaCIg6JQxAi3pDHtg5coVE5uGfP+DxoywF0CQsDyREueRZ+u4yNFWHo5I3XoGd9k1IE0uqyzL6Jcg/i3BCYh+Pu3I="
on_success: always # default: change
on_failure: always # default: always
#slack:
# This is the value "[Slack-Organisation]:[API-Key]#[channel]" just encrypted!
#rooms:
# Channels for slack integration (none right now)
#- secure: "D1PsxyGmPjfYKSG2Onymek1h8L6LGk/e3JGj9E5+Lvt91fLKd1bOJ7g+QtJsET8+L4uQesf5Aa2OlHrgKU0k6M3VY4isu9UXMyCI6SV/NULAyvtDYKjHvTg2IqSLCwBdE/lbjxTC5/0XxouZOcLhjPIG+zKky3AEpFbeRZS2xrqEb3xEiye6dpuUL4rIgbuGvmD7CLhu0u+6WbMFJUM0YH0s2myYiyBvCBq67zgDMbI8tXS3jXc9HAeCIPyKgPd3PKLws9lYIv16hv8lQyQixMeNoqfAi9YrSCxAU47N0PiRlgjPVLM81HfTE7UeilDN9n7RHAktFq/R6FhvMErszSFOuYrhbXinj3wlTr58TpBnwa2NkVkD1Z3iGLVverqaxRJSFeOSQ4Ewq0INW6O/zlSWueXBtOjLwvrMY6jjBAWD1yoKD56maBXwbZ0al6AxQaSAB79GbHEqFq40Vmm9o3ezv6s+sDw9++vELyI9fv5FQSCh5tMLI5hcZmpYWfp4QHOzGa31hVdwhK6YxjY1ydsbrO2lsAKtZvBOxDH4eidfdufKKV9VIBRMd7qhKtSErhL25pTvBEXVv6FoP8DKGrJehaCP9qcg7Jg47AhDldga59no9QZ/WuS5WjiltjbKTTlqNYnhINSTMOuLm1zksdP9M/oXzjnMhdtc5keUNx0="
#on_success: always # default: change
#on_failure: always # default: always
# This lists steps that are run before the installation step.
before_install:
# This disables XDebug which should speed up the build. One reason to remove this
# line is if you are trying to generate code coverage with PHPUnit.
- phpenv config-rm xdebug.ini
# Currently we are inside of the clone of your repository. We move up two
# directories to build the project.
- cd ../..
# Update Composer.
- composer selfupdate
# Install this project into a directory called "ci".
- composer create-project -n --no-dev --prefer-dist moodlerooms/moodle-plugin-ci ci ^1
# Update the $PATH so scripts from this project can be called easily.
- export PATH="$(cd ci/bin; pwd):$(cd ci/vendor/bin; pwd):$PATH"
# This lists steps that are run for installation and setup.
install:
# Run the default install. The overview of what this does:
# - Clone the Moodle project into a directory called moodle.
# - Create Moodle config.php, database, data directories, etc.
# - Copy your plugin into Moodle.
# - If your plugin has Behat features, then Behat will be setup.
# - If your plugin has unit tests, then PHPUnit will be setup.
- moodle-plugin-ci install
# This lists steps that are run for the purposes of testing. Any of
# these steps can be re-ordered or removed to your liking. And of
# course, you can add any of your own custom steps.
script:
# This step lints your PHP files to check for syntax errors.
- moodle-plugin-ci phplint
# This step runs the PHP Copy/Paste Detector on your plugin. This helps to find
# code duplication.
- moodle-plugin-ci phpcpd
# This step runs the PHP Mess Detector on your plugin. This helps to find potential
# problems with your code which can result in refactoring opportunities.
- moodle-plugin-ci phpmd
# This step runs the Moodle Code Checker to make sure that your plugin conforms to the
# Moodle coding standards. It is highly recommended that you keep this step.
- moodle-plugin-ci codechecker
# This step runs CSS Lint on the CSS files in your plugin.
- moodle-plugin-ci csslint
# This step runs YUI Shifter on the YUI modules in your plugin. This also checks to make
# sure that the YUI modules have been shifted.
- moodle-plugin-ci shifter
# This step runs JSHint on the Javascript files in your plugin.
- moodle-plugin-ci jshint
# This step runs some light validation on the plugin file structure and code. Validation can be plugin specific.
- moodle-plugin-ci validate
# This step runs the PHPUnit tests of your plugin. If your plugin has PHPUnit tests,
# then it is highly recommended that you keep this step.
- moodle-plugin-ci phpunit --coverage-clover
# This step runs the Behat tests of your plugin. If your plugin has Behat tests, then
# it is highly recommended that you keep this step.
- moodle-plugin-ci behat
# Now we view the coverage file!
- if [ -e "coverage.xml" ]; then echo "Show PHPUnit code coverage:"; cat coverage.xml; fi