diff --git a/tests/selenium.js b/tests/selenium.js index 365b6b2..dd148fe 100644 --- a/tests/selenium.js +++ b/tests/selenium.js @@ -126,7 +126,7 @@ var browser = wd.remote("localhost", 4445, process.env.SAUCE_USERNAME, process.env.SAUCE_ACCESS_KEY); var browserStream = new Bacon.Bus(); test.capabilities["tunnel-identifier"] = process.env.TRAVIS_JOB_NUMBER; - test.capabilities["name"] = process.env.TRAVIS_BUILD_NUMBER; + test.capabilities["name"] = process.env.TRAVIS_COMMIT + " #" + process.env.TRAVIS_BUILD_NUMBER; var resultStream = Bacon.fromNodeCallback(browser, "init", test.capabilities) .flatMap(Bacon.fromNodeCallback(browser, "setImplicitWaitTimeout", 15000) diff --git a/tests/test.js b/tests/test.js index 0a09a33..c7be748 100644 --- a/tests/test.js +++ b/tests/test.js @@ -13,9 +13,14 @@ var h2cSelector, h2cOptions; document.write(srcStart + '/tests/assets/jquery.plugin.html2canvas.js' + scrEnd); var html2canvas = ['log', 'nodecontainer', 'stackingcontext', 'textcontainer', 'support', 'imagecontainer', 'dummyimagecontainer', 'proxyimagecontainer', 'gradientcontainer', 'lineargradientcontainer', 'webkitgradientcontainer', 'imageloader', 'nodeparser', 'font', 'fontmetrics', 'core', 'renderer', 'promise', 'renderers/canvas'], i; - for (i = 0; i < html2canvas.length; ++i) { - document.write(srcStart + '/src/' + html2canvas[i] + '.js?' + Math.random() + scrEnd); + if (window.location.search === "?selenium") { + document.write(srcStart + '/build/html2canvas.js' + scrEnd); + } else { + for (i = 0; i < html2canvas.length; ++i) { + document.write(srcStart + '/src/' + html2canvas[i] + '.js?' + Math.random() + scrEnd); + } } + window.onload = function() { h2cSelector = [document.documentElement];