You are here

test-source-code.sh in Paragraphs Features 2.x

Same filename and directory in other branches
  1. 8 scripts/travis/test-source-code.sh
#!/usr/bin/env bash
# remove xdebug to make php execute faster
phpenv config-rm xdebug.ini

# globally require drupal coder for code tests
composer global require "symfony/yaml:^3.4" "drupal/coder"

# run phpcs
phpcs --config-set installed_paths ~/.composer/vendor/drupal/coder/coder_sniffer
phpcs --standard=Drupal --ignore=README.md -p .
phpcs --standard=DrupalPractice -p .

# JS ESLint checking
set -x
source ~/.nvm/nvm.sh
set +x
nvm install 6
npm install -g eslint
eslint .

File

scripts/travis/test-source-code.sh
View source
  1. #!/usr/bin/env bash
  2. # remove xdebug to make php execute faster
  3. phpenv config-rm xdebug.ini
  4. # globally require drupal coder for code tests
  5. composer global require "symfony/yaml:^3.4" "drupal/coder"
  6. # run phpcs
  7. phpcs --config-set installed_paths ~/.composer/vendor/drupal/coder/coder_sniffer
  8. phpcs --standard=Drupal --ignore=README.md -p .
  9. phpcs --standard=DrupalPractice -p .
  10. # JS ESLint checking
  11. set -x
  12. source ~/.nvm/nvm.sh
  13. set +x
  14. nvm install 6
  15. npm install -g eslint
  16. eslint .