-
-
Notifications
You must be signed in to change notification settings - Fork 55
Replace autostart behavior with hook to start tests. #176
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall looks good to me! Don't forget to update the Ember-CLI blueprints once this is released.
} | ||
}); | ||
|
||
export class TestLoader extends AbstractTestLoader { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Leaving this as a note to myself: if ember-exam breaks, come check this. I don't think it should though.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Gotcha. I just figured this was better than monkey patching the prototype.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Definitely is, just unsure if it breaks any assumptions in the ember-exam code (been awhile since I looked at it haha)
Irony: not updating the test-helper.js in this repo 😛 |
Prior to this change, tests automatically started once DOMContentLoaded fires. This means that there is no obvious mechanism to hook into the system after boot, but before tests start (e.g. to load lazy engine assets). This is a somewhat breaking change, apps will have to update their `tests/test-helper.js` to properly kick off the tests. The change is pretty trivial: ```js // tests/test-helper.js import { start } from 'ember-cli-qunit'; // ...snip current content... start(); ```
HAHA! Yes, I did forget that, but I also missed some other work that I had deleted and forgot to copy. Updated now, might want to do another pass... |
@rwjblue do we need something similar for |
@Turbo87 - Yes, if you want your API to follow suit... |
This has the nice side benefit of improving the ergo for debugging tests that loop, as you can open dev tools before running the tests that cause chrome to thrash. |
Prior to this change, tests automatically started once DOMContentLoaded fires. This means that there is no obvious mechanism to hook into the system after boot, but before
tests start (e.g. to load lazy engine assets).
This is a somewhat breaking change, apps will have to update their
tests/test-helper.js
to properly kick off the tests.The change is pretty trivial:
Closes #171.