Skip to content

Commit

Permalink
Add deactivate hook to Engine tests to verify proper teardown sequence
Browse files Browse the repository at this point in the history
  • Loading branch information
Trent Willis committed Sep 8, 2016
1 parent 6f5c3b8 commit 7276893
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,10 @@ moduleFor('Application test: engine rendering', class extends ApplicationTest {
this.register('route:application', Route.extend({
model() {
hooks.push('engine - application');
},
deactivate() {
// Ensures that the Engine isn't destroyed before resetting the router
this.set('isActive', false);
}
}));
}
Expand Down

0 comments on commit 7276893

Please sign in to comment.