From 3d3c59cea699655d3f0e6971fc1baa0516602ade Mon Sep 17 00:00:00 2001 From: John-David Dalton Date: Tue, 5 Nov 2013 08:58:19 -0800 Subject: [PATCH] Minor style tweaks and simplify travis.yml. --- .travis.yml | 8 ++++---- test/saucelabs.js | 9 ++++----- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/.travis.yml b/.travis.yml index c46f54957..2ea46dcbb 100644 --- a/.travis.yml +++ b/.travis.yml @@ -52,8 +52,8 @@ branches: only: - master before_install: - - "[ $BUILD != false ] && [ $BUILD != 'compat' ] && MAKE=true || true" - - "[ $BUILD != 'mobile' ] && [ $BUILD != 'modern' ] && COMPAT=true || true" + - "([ $BUILD == 'legacy' ] || [ $BUILD == 'mobile' ] || [ $BUILD == 'modern' ]) && MAKE=true || true" + - "([ $BUILD == 'compat' ] || [ $BUILD == 'legacy' ]) && COMPAT=true || true" - "[ $SAUCE_LABS != false ] && npm i ecstatic@\"~0.4.0\" request@\"~2.27.0\" sauce-tunnel@\"~1.1.0\" || true" - "[ $BIN == 'istanbul' ] && npm i -g istanbul@\"~0.1.0\" || true" - "[ $BIN == 'narwhal' ] && wget https://github.com/280north/narwhal/archive/v0.3.2.zip && sudo unzip v0.3.2 -d /opt/ && rm v0.3.2.zip || true" @@ -76,5 +76,5 @@ script: - "[ $SAUCE_LABS == false ] && true || node ./test/saucelabs.js \"test/backbone.html?build=../dist/lodash.$BUILD.js\"" - "[ $SAUCE_LABS == false ] && true || node ./test/saucelabs.js \"test/underscore.html?build=lodash-$BUILD\"" - "[ $SAUCE_LABS == false ] && true || node ./test/saucelabs.js \"test/underscore.html?build=../dist/lodash.$BUILD.js\"" - - "([ $SAUCE_LABS == false ] || [ $BUILD == 'underscore' ] || [ $COMPAT == false ]) && true || node ./test/saucelabs.js \"test/index.html?build=lodash-$BUILD&compat=7\"" - - "([ $SAUCE_LABS == false ] || [ $BUILD == 'underscore' ] || [ $COMPAT == false ]) && true || node ./test/saucelabs.js \"test/index.html?build=../dist/lodash.$BUILD.js&compat=7\"" + - "([ $SAUCE_LABS == false ] || [ $COMPAT == false ]) && true || node ./test/saucelabs.js \"test/index.html?build=lodash-$BUILD&compat=7\"" + - "([ $SAUCE_LABS == false ] || [ $COMPAT == false ]) && true || node ./test/saucelabs.js \"test/index.html?build=../dist/lodash.$BUILD.js&compat=7\"" diff --git a/test/saucelabs.js b/test/saucelabs.js index 9ca7ed70a..c58e34de3 100644 --- a/test/saucelabs.js +++ b/test/saucelabs.js @@ -51,7 +51,7 @@ ['Windows 7', 'safari', '5'] ]; - // test IE compat mode + // platforms to test IE compat mode if (runnerQuery.compat) { platforms = [ ['WIN8.1', 'internet explorer', '11'], @@ -86,13 +86,12 @@ // create a web server for the local dir var mount = ecstatic({ - root: process.cwd(), - cache: false + 'root': process.cwd(), + 'cache': false }); http.createServer(function(req, res) { - var parsedUrl = url.parse(req.url, true); - var compat = parsedUrl.query.compat; + var compat = url.parse(req.url, true).query.compat; if (compat) { // see http://msdn.microsoft.com/en-us/library/ff955275(v=vs.85).aspx res.setHeader('X-UA-Compatible', 'IE=' + compat);