mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-05 01:17:50 +00:00
Remove extraneous quotes from travis.yml.
This commit is contained in:
87
.travis.yml
87
.travis.yml
@@ -2,51 +2,59 @@ language: node_js
|
|||||||
sudo: false
|
sudo: false
|
||||||
node_js:
|
node_js:
|
||||||
- "6"
|
- "6"
|
||||||
|
|
||||||
cache:
|
cache:
|
||||||
directories:
|
directories:
|
||||||
- $HOME/.npm
|
- $HOME/.npm
|
||||||
- travis_phantomjs
|
- travis_phantomjs
|
||||||
|
|
||||||
env:
|
env:
|
||||||
global:
|
global:
|
||||||
- BIN="node" ISTANBUL=false OPTION=""
|
- BIN="node" ISTANBUL=false OPTION=""
|
||||||
- SAUCE_LABS=false SAUCE_USERNAME="lodash"
|
- SAUCE_LABS=false SAUCE_USERNAME="lodash"
|
||||||
- secure: "tg1JFsIFnxzLaTboFPOnm+aJCuMm5+JdhLlESlqg9x3fwro++7KCnwHKLNovhchaPe4otC43ZMB/nfWhDnDm11dKbm/V6HlTkED+dadTsaLxVDg6J+7yK41QhokBPJOxLV78iDaNaAQVYEirAgZ0yn8kFubxmNKV+bpCGQNc9yU="
|
- secure: "tg1JFsIFnxzLaTboFPOnm+aJCuMm5+JdhLlESlqg9x3fwro++7KCnwHKLNovhchaPe4otC43ZMB/nfWhDnDm11dKbm/V6HlTkED+dadTsaLxVDg6J+7yK41QhokBPJOxLV78iDaNaAQVYEirAgZ0yn8kFubxmNKV+bpCGQNc9yU="
|
||||||
|
|
||||||
matrix:
|
matrix:
|
||||||
-
|
-
|
||||||
- BIN="phantomjs"
|
- BIN="phantomjs"
|
||||||
- ISTANBUL=true
|
- ISTANBUL=true
|
||||||
- SAUCE_LABS=true
|
- SAUCE_LABS=true
|
||||||
|
|
||||||
matrix:
|
matrix:
|
||||||
include:
|
include:
|
||||||
- node_js: "4"
|
- node_js: "4"
|
||||||
env:
|
env:
|
||||||
|
|
||||||
git:
|
git:
|
||||||
depth: 10
|
depth: 10
|
||||||
|
|
||||||
branches:
|
branches:
|
||||||
only:
|
only:
|
||||||
- master
|
- master
|
||||||
|
|
||||||
notifications:
|
notifications:
|
||||||
webhooks:
|
webhooks:
|
||||||
urls:
|
urls:
|
||||||
- https://webhooks.gitter.im/e/4aab6358b0e9aed0b628
|
- https://webhooks.gitter.im/e/4aab6358b0e9aed0b628
|
||||||
on_success: change
|
on_success: change
|
||||||
on_failure: always
|
on_failure: always
|
||||||
|
|
||||||
before_install:
|
before_install:
|
||||||
# Upgrade PhantomJS to v2.1.1.
|
# Upgrade PhantomJS to v2.1.1.
|
||||||
- "export PHANTOMJS_VERSION=2.1.1"
|
- export PHANTOMJS_VERSION=2.1.1
|
||||||
- "export PATH=$PWD/travis_phantomjs/phantomjs-$PHANTOMJS_VERSION-linux-x86_64/bin:$PATH"
|
- export PATH=$PWD/travis_phantomjs/phantomjs-$PHANTOMJS_VERSION-linux-x86_64/bin:$PATH
|
||||||
- "if [ $(phantomjs --version) != $PHANTOMJS_VERSION ]; then rm -rf $PWD/travis_phantomjs; mkdir -p $PWD/travis_phantomjs; fi"
|
- if [ $(phantomjs --version) != $PHANTOMJS_VERSION ]; then rm -rf $PWD/travis_phantomjs; mkdir -p $PWD/travis_phantomjs; fi
|
||||||
- "if [ $(phantomjs --version) != $PHANTOMJS_VERSION ]; then wget https://github.com/Medium/phantomjs/releases/download/v$PHANTOMJS_VERSION/phantomjs-$PHANTOMJS_VERSION-linux-x86_64.tar.bz2 -O $PWD/travis_phantomjs/phantomjs-$PHANTOMJS_VERSION-linux-x86_64.tar.bz2; fi"
|
- if [ $(phantomjs --version) != $PHANTOMJS_VERSION ]; then wget https://github.com/Medium/phantomjs/releases/download/v$PHANTOMJS_VERSION/phantomjs-$PHANTOMJS_VERSION-linux-x86_64.tar.bz2 -O $PWD/travis_phantomjs/phantomjs-$PHANTOMJS_VERSION-linux-x86_64.tar.bz2; fi
|
||||||
- "if [ $(phantomjs --version) != $PHANTOMJS_VERSION ]; then tar -xvf $PWD/travis_phantomjs/phantomjs-$PHANTOMJS_VERSION-linux-x86_64.tar.bz2 -C $PWD/travis_phantomjs; fi"
|
- if [ $(phantomjs --version) != $PHANTOMJS_VERSION ]; then tar -xvf $PWD/travis_phantomjs/phantomjs-$PHANTOMJS_VERSION-linux-x86_64.tar.bz2 -C $PWD/travis_phantomjs; fi
|
||||||
- "phantomjs --version"
|
- phantomjs --version
|
||||||
|
|
||||||
# Use exact Node version.
|
# Use exact Node version.
|
||||||
- "nvm use $TRAVIS_NODE_VERSION"
|
- nvm use $TRAVIS_NODE_VERSION
|
||||||
|
|
||||||
# Setup npm.
|
# Setup npm.
|
||||||
- "npm set loglevel error"
|
- npm set loglevel error
|
||||||
- "npm set progress false"
|
- npm set progress false
|
||||||
- "npm i -g npm@\"^2.0.0\""
|
- npm i -g npm@"^2.0.0"
|
||||||
|
|
||||||
# Remove code skipped on the coverage run.
|
# Remove code skipped on the coverage run.
|
||||||
- |
|
- |
|
||||||
@@ -67,32 +75,47 @@ before_install:
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Use lodash-cli from GitHub.
|
# Use lodash-cli from GitHub.
|
||||||
- "git clone --depth=10 --branch=master git://github.com/lodash/lodash-cli ./node_modules/lodash-cli"
|
- git clone --depth=10 --branch=master git://github.com/lodash/lodash-cli ./node_modules/lodash-cli
|
||||||
- "mkdir -p ./node_modules/lodash-cli/node_modules/lodash && cd $_ && cp ../../../../lodash.js ./lodash.js && cp ../../../../package.json ./package.json"
|
- mkdir -p ./node_modules/lodash-cli/node_modules/lodash && cd $_ && cp ../../../../lodash.js ./lodash.js && cp ../../../../package.json ./package.json
|
||||||
- "cd ../../ && npm i --production && cd ../../"
|
- cd ../../ && npm i --production && cd ../../
|
||||||
|
|
||||||
script:
|
script:
|
||||||
# Detect code coverage.
|
# Detect code coverage.
|
||||||
- "[ $ISTANBUL == false ] || istanbul cover -x \"**/vendor/**\" --report lcovonly ./test/test.js -- ./lodash.js"
|
- |
|
||||||
- "[ $ISTANBUL == false ] || [ $TRAVIS_SECURE_ENV_VARS == false ] || (cat ./coverage/lcov.info | coveralls) || true"
|
if [ $ISTANBUL == true ]; then
|
||||||
- "[ $ISTANBUL == false ] || [ $TRAVIS_SECURE_ENV_VARS == false ] || (cat ./coverage/coverage.json | codecov) || true"
|
istanbul cover -x "**/vendor/**" --report lcovonly ./test/test.js -- ./lodash.js
|
||||||
|
if [ $TRAVIS_SECURE_ENV_VARS == true ]; then
|
||||||
|
cat ./coverage/lcov.info | coveralls
|
||||||
|
cat ./coverage/coverage.json | codecov
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
# Test in Node.js and PhantomJS.
|
# Test in Node.js and PhantomJS.
|
||||||
- "[ $ISTANBUL == true ] || node ./node_modules/lodash-cli/bin/lodash -o ./dist/lodash.js"
|
- |
|
||||||
- "[ $ISTANBUL == true ] || (node ./node_modules/lodash-cli/bin/lodash modularize exports=node -o ./ && node ./node_modules/lodash-cli/bin/lodash -d -o ./lodash.js)"
|
if [ $ISTANBUL == false ]; then
|
||||||
- "[ $ISTANBUL == true ] || [ $SAUCE_LABS == true ] || cd ./test"
|
node ./node_modules/lodash-cli/bin/lodash -o ./dist/lodash.js
|
||||||
- "[ $ISTANBUL == true ] || [ $SAUCE_LABS == true ] || $BIN $OPTION ./test.js ../lodash.js"
|
node ./node_modules/lodash-cli/bin/lodash modularize exports=node -o ./ && node ./node_modules/lodash-cli/bin/lodash -d -o ./lodash.js
|
||||||
- "[ $ISTANBUL == true ] || [ $SAUCE_LABS == true ] || [ $TRAVIS_SECURE_ENV_VARS == false ] || $BIN $OPTION ./test.js ../dist/lodash.min.js"
|
if [ $SAUCE_LABS == false ]; then
|
||||||
|
cd ./test
|
||||||
|
$BIN $OPTION ./test.js ../lodash.js
|
||||||
|
if [ $TRAVIS_SECURE_ENV_VARS == true ]; then
|
||||||
|
$BIN $OPTION ./test.js ../dist/lodash.min.js
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
# Test in Sauce Labs.
|
# Test in Sauce Labs.
|
||||||
- "[ $SAUCE_LABS == false ] || node ./node_modules/lodash-cli/bin/lodash core -o ./dist/lodash.core.js"
|
- |
|
||||||
- "[ $SAUCE_LABS == false ] || npm run build"
|
if [ $SAUCE_LABS == true ]; then
|
||||||
- "[ $SAUCE_LABS == false ] || $BIN ./test/saucelabs.js name=\"lodash tests\" runner=\"test/index.html?build=../dist/lodash.js&noglobals=true\" tags=\"development\""
|
node ./node_modules/lodash-cli/bin/lodash core -o ./dist/lodash.core.js
|
||||||
- "[ $SAUCE_LABS == false ] || $BIN ./test/saucelabs.js name=\"lodash tests\" runner=\"test/index.html?build=../dist/lodash.min.js&noglobals=true\" tags=\"production\""
|
npm run build
|
||||||
- "[ $SAUCE_LABS == false ] || $BIN ./test/saucelabs.js name=\"lodash-fp tests\" runner=\"test/fp.html?noglobals=true\" tags=\"development\""
|
$BIN ./test/saucelabs.js name="lodash tests" runner="test/index.html?build=../dist/lodash.js&noglobals=true" tags="development"
|
||||||
- "[ $SAUCE_LABS == false ] || $BIN ./test/saucelabs.js name=\"underscore tests\" runner=\"test/underscore.html?build=../dist/lodash.js\" tags=\"development,underscore\""
|
$BIN ./test/saucelabs.js name="lodash tests" runner="test/index.html?build=../dist/lodash.min.js&noglobals=true" tags="production"
|
||||||
- "[ $SAUCE_LABS == false ] || $BIN ./test/saucelabs.js name=\"underscore tests\" runner=\"test/underscore.html?build=../dist/lodash.min.js\" tags=\"production,underscore\""
|
$BIN ./test/saucelabs.js name="lodash-fp tests" runner="test/fp.html?noglobals=true" tags="development"
|
||||||
- "[ $SAUCE_LABS == false ] || $BIN ./test/saucelabs.js name=\"backbone tests\" runner=\"test/backbone.html?build=../dist/lodash.js\" tags=\"development,backbone\""
|
$BIN ./test/saucelabs.js name="underscore tests" runner="test/underscore.html?build=../dist/lodash.js" tags="development,underscore"
|
||||||
- "[ $SAUCE_LABS == false ] || $BIN ./test/saucelabs.js name=\"backbone tests\" runner=\"test/backbone.html?build=../dist/lodash.min.js\" tags=\"production,backbone\""
|
$BIN ./test/saucelabs.js name="underscore tests" runner="test/underscore.html?build=../dist/lodash.min.js" tags="production,underscore"
|
||||||
- "[ $SAUCE_LABS == false ] || $BIN ./test/saucelabs.js name=\"backbone tests\" runner=\"test/backbone.html?build=../dist/lodash.core.js\" tags=\"development,backbone\""
|
$BIN ./test/saucelabs.js name="backbone tests" runner="test/backbone.html?build=../dist/lodash.js" tags="development,backbone"
|
||||||
- "[ $SAUCE_LABS == false ] || $BIN ./test/saucelabs.js name=\"backbone tests\" runner=\"test/backbone.html?build=../dist/lodash.core.min.js\" tags=\"production,backbone\""
|
$BIN ./test/saucelabs.js name="backbone tests" runner="test/backbone.html?build=../dist/lodash.min.js" tags="production,backbone"
|
||||||
|
$BIN ./test/saucelabs.js name="backbone tests" runner="test/backbone.html?build=../dist/lodash.core.js" tags="development,backbone"
|
||||||
|
$BIN ./test/saucelabs.js name="backbone tests" runner="test/backbone.html?build=../dist/lodash.core.min.js" tags="production,backbone"
|
||||||
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user