-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
132 lines (116 loc) · 3.82 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
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
language: php
php:
- 5.6
- 7.0
- hhvm
# This helps builds go quicker on Travis since it enables caching of dependencies
# http://docs.travis-ci.com/user/workers/container-based-infrastructure/
sudo: false
# Do not limit history to latest commits. Merge commits will need older commits.
# Limiting depth caused issues with /.scripts/travis/check_commit_msgs.sh
#git:
# depth: 1
branches:
except:
- 1.0
- 1.5
- 1.6
- 1.7
- 1.8
matrix:
fast_finish: true
allow_failures:
- php: hhvm
include:
# Lint checks for PHP code and composer.json
- php: 5.6
env: VARIA=true
before_install:
- phpenv config-rm xdebug.ini
install:
- phpenv rehash
- composer travis:install
script:
- bash .scripts/travis/check_commit_msgs.sh
- composer lint
# Build and test javascript
- php: 5.6
env: VARIA=true
before_install:
- phpenv config-rm xdebug.ini
install:
- npm install
- composer travis:install
script:
- npm test
# Build docs and check for errors
# Flags used here, not in `make html`:
# -n Run in nit-picky mode. Currently, this generates warnings for all missing references.
# -W Turn warnings into errors. This means that the build stops at the first warning and sphinx-build exits with exit status 1.
- php: 5.6
env: VARIA=true
install:
- pip install --user "Sphinx==1.3.1"
- pip install --user "sphinx-intl"
- export PATH=$PATH:$HOME/.local/bin
script:
- sphinx-build -b html -nW docs docs/_build/html
- sphinx-build -b latex -nW docs docs/_build/latex
- sphinx-intl build --locale-dir=docs/locale/
- sphinx-build -b html -D language=es -n docs docs/_build/html
# Memcached enabled
- php: 5.6
services:
- memcached
- mysql
env: VARIA=true
before_install:
- phpenv config-rm xdebug.ini
- phpenv config-add ./.scripts/travis/memcached.ini
install:
- composer travis:install-with-mysql
script:
- php -f ./.scripts/is_memcached_enabled.php
- ./vendor/bin/phpunit --configuration ./.scripts/travis/phpunit-memcached.xml
- php ./engine/tests/suite.php --config ./.scripts/travis/elgg-config/simpletest_memcached.php
# End to end tests
- php: 5.6
env: E2E=true
before_install:
- phpenv config-rm xdebug.ini
install:
- composer travis:install-with-mysql
- php -S localhost:8888 index.php &
- sleep 3 # give Web server some time to bind to sockets, etc
script:
- curl -o - http://localhost:8888/ | grep "<title>Elgg Travis Site</title>"
- ./vendor/bin/phpunit
- php -f ./engine/tests/suite.php
services:
- mysql
before_install:
- phpenv config-rm xdebug.ini
- composer config -g github-oauth.github.com ${GITHUB_TOKEN}
install: composer travis:install-with-mysql
script:
- ./vendor/bin/phpunit
- php -f ./engine/tests/suite.php
notifications:
email:
secure: exC/ws07lLOj3Y43C89jiaKpyB8Yt7DPGSCShV4R3Wkw/hVVzjxt1BinPxzsyL5DC7APUMcTHGOhDB2oCE4ynDE6o6L9bH79fc+V8IYAiNaEIGL0AOuHdnRdGN9GMrr2jv78cZ5MctuUTkeYLaoOEyDGHmkMhqa6SufIDAY8b58=
webhooks:
urls:
- secure: "Ug81+4Fa2UFZetSCV79OWOgYi4uVgNQ6rVrVn2HElddOMDwuHxo9CYKoA3Q+joPKMtNFCN2qkMyoyUfIMM83uJi1LmaUx/c7lR1pXBFVgc4Xyt114NcY80I4OCWWKg0G1FDlSiaXil922JjeC3MekYoqjsIyUgabGihe6j7DWz0="
on_start: true
slack:
secure: elgg:qUNTV70bSXTkIdr7b4FjvFhm
on_failure: always
on_success: never
env:
global:
secure: "fdpCjdC0Qp/ZJqtrCHE4I/tHXWF1sORftm6khd6geqK7d4qWzIh6HzNN2BlF+2m4nyuyxo2wzPm/oGoqogVpBgrzpQ7SZl7h2/wzgs2C/k39sFGyDisLesTM5DhBDJWcomyqtcnQmKn340Z9KOxiHAt4FOj2FZVN5+tIO5j3Cks="
## Cache dependencies
cache:
directories:
- $HOME/.composer/cache
- $HOME/.npm