From 384f632a34ff9847224797a2e2fb569db87f36d8 Mon Sep 17 00:00:00 2001 From: Steven Glanzer Date: Mon, 27 Apr 2015 21:23:15 -0400 Subject: [PATCH 1/2] Preserve Qunit autostart configuration --- vendor/blanket-require.js | 4 ++++ vendor/start.js | 6 +----- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/vendor/blanket-require.js b/vendor/blanket-require.js index 4c43310..3c11189 100644 --- a/vendor/blanket-require.js +++ b/vendor/blanket-require.js @@ -42,6 +42,10 @@ var blanketLoader = function(moduleName) { // Defer the start of the test run until a call to QUnit.start() this // allows the modules to be loaded/instrumented prior to the test run if (typeof(QUnit) === 'object') { + var autostart = QUnit.config.autostart; + window._$blanket_qunit = { + autostart: autostart + }; QUnit.config.autostart = false; } diff --git a/vendor/start.js b/vendor/start.js index 86f0af5..80f9c7f 100644 --- a/vendor/start.js +++ b/vendor/start.js @@ -22,11 +22,7 @@ function cliFinish() { blanket.onTestsDone = cliFinish; if (typeof(QUnit) === 'object') { - // I'm not sure which ember-cli release introduced this behavior, - // but QUnit.start() is called by the ember-cli framework as of - // ember-cli@0.1.15 and causes a conflict if QUnit.start() is - // called again here - // QUnit.start(); + QUnit.config.autostart = window._$blanket_qunit.autostart; } else if (typeof(mocha) === 'object') { From 991b827840cef449474dae75f8b2a7a2de0135e0 Mon Sep 17 00:00:00 2001 From: Steven Glanzer Date: Mon, 27 Apr 2015 21:29:46 -0400 Subject: [PATCH 2/2] Adding QUnit to jshint globals in start.js --- vendor/start.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vendor/start.js b/vendor/start.js index 80f9c7f..6daf5d1 100644 --- a/vendor/start.js +++ b/vendor/start.js @@ -1,4 +1,4 @@ -/*global blanket, mocha, moduleLoaderFinish, $ */ +/*global QUnit, blanket, mocha, moduleLoaderFinish, $ */ function sendCoverage() { $.ajax({