2 # .travis.yml - Drupal for Travis CI Integration
4 # Template provided by https://github.com/LionsAd/drupal_ti.
6 # Based for simpletest upon:
7 # https://github.com/sonnym/travis-ci-drupal-module-example
14 - $HOME/.composer/cache
33 # add composer's global bin directory to the path
34 # see: https://github.com/drush-ops/drush#install---composer
35 - PATH="$PATH:$HOME/.composer/vendor/bin"
37 # Configuration variables.
38 - DRUPAL_TI_MODULE_NAME="crop"
39 - DRUPAL_TI_SIMPLETEST_GROUP="crop"
41 # Define runners and environment vars to include before and after the
42 # main runners / environment vars.
43 #- DRUPAL_TI_SCRIPT_DIR_BEFORE="./drupal_ti/before"
44 #- DRUPAL_TI_SCRIPT_DIR_AFTER="./drupal_ti/after"
46 # The environment to use, supported are: drupal-7, drupal-8
47 - DRUPAL_TI_ENVIRONMENT="drupal-8"
49 # Drupal specific variables.
50 - DRUPAL_TI_DB="drupal_travis_db"
51 - DRUPAL_TI_DB_URL="mysql://root:@127.0.0.1/drupal_travis_db"
52 # Note: Do not add a trailing slash here.
53 - DRUPAL_TI_WEBSERVER_URL="http://127.0.0.1"
54 - DRUPAL_TI_WEBSERVER_PORT="8080"
56 # Simpletest specific commandline arguments, the DRUPAL_TI_SIMPLETEST_GROUP is appended at the end.
57 - DRUPAL_TI_SIMPLETEST_ARGS="--verbose --color --concurrency 4 --url $DRUPAL_TI_WEBSERVER_URL:$DRUPAL_TI_WEBSERVER_PORT"
59 # === Behat specific variables.
60 # This is relative to $TRAVIS_BUILD_DIR
61 - DRUPAL_TI_BEHAT_DIR="./tests/behat"
62 # These arguments are passed to the bin/behat command.
63 - DRUPAL_TI_BEHAT_ARGS=""
64 # Specify the filename of the behat.yml with the $DRUPAL_TI_DRUPAL_DIR variables.
65 - DRUPAL_TI_BEHAT_YML="behat.yml.dist"
66 # This is used to setup Xvfb.
67 - DRUPAL_TI_BEHAT_SCREENSIZE_COLOR="1280x1024x16"
68 # The version of seleniumthat should be used.
69 - DRUPAL_TI_BEHAT_SELENIUM_VERSION="2.44"
71 # PHPUnit specific commandline arguments.
72 - DRUPAL_TI_PHPUNIT_ARGS=""
74 # Code coverage via coveralls.io
75 - DRUPAL_TI_COVERAGE="satooshi/php-coveralls:0.6.*"
76 # This needs to match your .coveralls.yml file.
77 - DRUPAL_TI_COVERAGE_FILE="build/logs/clover.xml"
80 #- DRUPAL_TI_DEBUG="-x -v"
81 # Set to "all" to output all files, set to e.g. "xvfb selenium" or "selenium",
82 # etc. to only output those channels.
83 #- DRUPAL_TI_DEBUG_FILE_OUTPUT="selenium xvfb webserver"
86 # [[[ SELECT ANY OR MORE OPTIONS ]]]
87 #- DRUPAL_TI_RUNNERS="phpunit"
88 - DRUPAL_TI_RUNNERS="simpletest"
89 #- DRUPAL_TI_RUNNERS="behat"
90 #- DRUPAL_TI_RUNNERS="phpunit simpletest behat"
93 database: drupal_travis_db
98 - composer self-update
99 - composer global require "lionsad/drupal_ti:1.*"
100 - drupal-ti before_install
101 # Codesniffer and Coder
102 - composer global require "squizlabs/php_codesniffer:2.0.*@dev"
103 - composer global require drupal/coder:8.2.0-beta1
104 - ln -s ~/.composer/vendor/drupal/coder/coder_sniffer/Drupal ~/.composer/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/
110 - drupal-ti before_script
113 - drupal-ti --include .travis-phpcs.sh
117 - drupal-ti after_script