Skip to content

Commit

Permalink
[BUGFIX lts] Fix test issues exposed by not swallowing errors.
Browse files Browse the repository at this point in the history
Previously, due to always running within a try/catch these errors were
swallowed in production build test runs.
  • Loading branch information
rwjblue committed Sep 21, 2017
1 parent 6e24523 commit db55502
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions packages/ember-runtime/tests/system/object/create_test.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,9 +115,9 @@ QUnit.test('inherits properties from passed in EmberObject', function() {
});

QUnit.test('throws if you try to pass anything a string as a parameter', function() {
let expected = 'EmberObject.create only accepts an objects.';
let expected = 'Ember.Object.create only accepts objects.';

throws(() => EmberObject.create('some-string'), expected);
expectAssertion(() => EmberObject.create('some-string'), expected);
});

QUnit.test('EmberObject.create can take undefined as a parameter', function() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -564,7 +564,7 @@ moduleFor('The {{link-to}} helper + query params - globals mode app', class exte
[`@test the {{link-to}} helper throws a useful error if you invoke it wrong`](assert) {
assert.expect(1);

assert.throws(() => {
expectAssertion(() => {
this.runTask(() => {
this.createApplication();

Expand All @@ -574,6 +574,6 @@ moduleFor('The {{link-to}} helper + query params - globals mode app', class exte

this.addTemplate('application', `{{#link-to id='the-link'}}Index{{/link-to}}`);
});
}, /(You must provide one or more parameters to the link-to component.|undefined is not an object)/);
}, /You must provide one or more parameters to the link-to component/);
}
});
});

0 comments on commit db55502

Please sign in to comment.