diff --git a/vendor/ember-qunit-assert-helpers-loader.js b/vendor/ember-qunit-assert-helpers-loader.js index e7b8118..f199051 100644 --- a/vendor/ember-qunit-assert-helpers-loader.js +++ b/vendor/ember-qunit-assert-helpers-loader.js @@ -1,4 +1,21 @@ -/* globals require */ - -// Loading the file here will install the asserts onto `QUnit.Assert` class. -require('ember-qunit-assert-helpers/test-support/install-qunit-asserts'); +// This file is appended to `test-support.js`. +// It automatically requires the `install-qunit-asserts` entrypoint module to +// install the assertions onto `Qunit`. +// +// With `ember-auto-import@1` all vanilla JS dependencies, like `qunit`, are +// eagerly bundled into either `vendor.js` or `test-support.js`. +// Therefore they are available, when this module is evaluated. +// +// With `ember-auto-import@2` these dependencies are placed into extra +// `*.chunk.js` files instead. These files are loaded _after_ `vendor.js` and +// `test-support.js`. Therefore they are not available, when this module is +// evaluated. +// To fix this, we delay the evaluation of the entry point until the +// `DOMContentLoaded` event occurs, by which all `