Skip to content

Commit

Permalink
Merge pull request #17712 from simonihmig/blueprint-qunit-instance-init
Browse files Browse the repository at this point in the history
Instance-initializer blueprint: destroy instance before application
  • Loading branch information
rwjblue authored Mar 8, 2019
2 parents 1a9f464 + bff547d commit 57371db
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ module('<%= friendlyTestName %>', function(hooks) {
this.instance = this.application.buildInstance();
});
hooks.afterEach(function() {
<% if (destroyAppExists) { %>destroyApp(this.application);<% } else { %>run(this.application, 'destroy');<% } %>
<% if (destroyAppExists) { %>destroyApp(this.instance);<% } else { %>run(this.instance, 'destroy');<% } %>
<% if (destroyAppExists) { %>destroyApp(this.application);<% } else { %>run(this.application, 'destroy');<% } %>
});

// Replace this with your real tests.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ module('Unit | Instance Initializer | foo', function(hooks) {
this.instance = this.application.buildInstance();
});
hooks.afterEach(function() {
run(this.application, 'destroy');
run(this.instance, 'destroy');
run(this.application, 'destroy');
});

// Replace this with your real tests.
Expand Down
2 changes: 1 addition & 1 deletion node-tests/fixtures/instance-initializer-test/rfc232.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ module('Unit | Instance Initializer | foo', function(hooks) {
this.instance = this.application.buildInstance();
});
hooks.afterEach(function() {
run(this.application, 'destroy');
run(this.instance, 'destroy');
run(this.application, 'destroy');
});

// Replace this with your real tests.
Expand Down

0 comments on commit 57371db

Please sign in to comment.