diff --git a/.travis.yml.dist b/.travis.yml.dist index b5367d3..126adc7 100644 --- a/.travis.yml.dist +++ b/.travis.yml.dist @@ -32,6 +32,10 @@ env: # Configuration variables. - DRUPAL_TI_MODULE_NAME="[[[FILL THIS OUT]]]" - DRUPAL_TI_SIMPLETEST_GROUP="[[[FILL THIS OUT]]]" + # This Composer version of the module is going to be used for testing. + # If you don't specify the version here, *@dev is going to be used. + # For more information read: https://www.drupal.org/node/2718229 + #- DRUPAL_TI_MODULE_COMPOSER_VERSION="[[[FILL THIS OUT]]]" # Define runners and environment vars to include before and after the # main runners / environment vars. diff --git a/environments/drupal-8.sh b/environments/drupal-8.sh index 5cb3e2b..f25a423 100644 --- a/environments/drupal-8.sh +++ b/environments/drupal-8.sh @@ -31,7 +31,12 @@ function drupal_ti_ensure_module_linked() { # the local repository must be the first in the list. composer config repositories.0 path $TRAVIS_BUILD_DIR composer config repositories.1 composer https://packages.drupal.org/8 - composer require drupal/$DRUPAL_TI_MODULE_NAME *@dev + if [ -z "$DRUPAL_TI_MODULE_COMPOSER_VERSION" ] + then + composer require "drupal/$DRUPAL_TI_MODULE_NAME" *@dev + else + composer require "drupal/$DRUPAL_TI_MODULE_NAME" "$DRUPAL_TI_MODULE_COMPOSER_VERSION" + fi } export DRUPAL_TI_DRUSH_VERSION="drush/drush:8.0.*"