-
Notifications
You must be signed in to change notification settings - Fork 11
/
.travis.yml
74 lines (59 loc) · 2.34 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
language: php
php:
- 5.5
- 5.6
matrix:
allow_failures:
- php: 5.5
env:
global:
# Install composer binaries into local bin directory.
# see: http://www.drush.org/en/master/install-alternative/#install-a-global-drush-via-composer
- COMPOSER_BIN_DIR="$HOME/bin"
- PATH="$COMPOSER_BIN_DIR:$PATH"
mysql:
database: suitcase
username: root
encoding: utf8
before_install:
- sudo apt-get update > /dev/null
- composer self-update
- mkdir -p "$COMPOSER_BIN_DIR"
install:
# install php packages required for running a web server from drush on php 5.3
- sudo apt-get install -y --force-yes php5-cgi php5-mysql
# install drush globally
- composer global require drush/drush:6.*
before_script:
# navigate out of module directory to prevent blown stack by recursive module lookup
- cd ../..
# create new site, stubbing sendmail path with true to prevent delivery errors and manually resolving drush path
- mysql -e 'create database suitcase'
- echo 'sendmail_path="/bin/true"' | tee -a "$(php --ini | grep "Loaded Configuration" | awk '{print $4}')"
- drush --yes core-quick-drupal --profile=testing --no-server --db-url=mysql://root:@127.0.0.1/suitcase --enable=simpletest suitcase
# reference and enable travis_ci_drupal_module_example in build site
- ln -s $(readlink -e $(cd -)) suitcase/drupal/sites/all/themes/suitcase
- cd suitcase/drupal/sites/all/modules/
- git clone https://github.com/isubit/luggage_ckeditor.git
- git clone https://github.com/isubit/luggage_contrib.git
- git clone https://github.com/isubit/luggage_core.git
- git clone https://github.com/isubit/luggage_roles.git
- drush --yes pm-enable suitcase luggage_ckeditor luggage_contrib luggage_core luggage_roles
- drush fra -y
- drush cc all
- drush en simpletest -y
- drush status
# start a web server on port 8080, run in the background; wait for initialization
- drush runserver --server=builtin 8080 &
- sleep 4
- drush vset --yes simpletest_verbose FALSE
# - until netstat -an 2>/dev/null | grep '8080.*LISTEN'; do true; done
script:
- drush test-run 'suitcase' --debug --uri=http://127.0.0.1:8080
# script: drush test-run 'Travis-CI Drupal Module Example' --uri=http://127.0.0.1:8080
notifications:
email: false
irc:
channels: "chat.freenode.net##luggage"
on_success: never
on_failure: never