Skip to content

Commit

Permalink
Move throws assertion to unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
Dan Wenzel committed Apr 9, 2018
1 parent 5117107 commit 254bd5d
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 40 deletions.
40 changes: 0 additions & 40 deletions tests/integration/components/freestyle-dynamic/component-test.js

This file was deleted.

13 changes: 13 additions & 0 deletions tests/unit/components/freestyle-dynamic/component-test.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import { moduleForComponent, test } from 'ember-qunit';

moduleForComponent('freestyle-dynamic', 'Unit | Component | freestyle dynamic', {
unit: true
});

test('an assertion is thrown if dynamicProperties is undefined', function(assert) {
assert.expect(1);

assert.throws(() => {
this.subject({ dynamicProperties: undefined });
}, /Assertion Failed: dynamicProperties passed into freestyle-dynamic must be an object. {2}You passed: undefined/)
});

0 comments on commit 254bd5d

Please sign in to comment.