Skip to content

Commit

Permalink
adding coverage for {{component}} keyword
Browse files Browse the repository at this point in the history
As suggested by @rwjblue [here](emberjs#60 (comment)).
  • Loading branch information
ef4 committed Jun 15, 2015
1 parent 3dc9376 commit ad1523e
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions tests/test-module-for-component-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,15 @@ test('can lookup components in its layout', function() {
equal(component._state, 'inDOM');
});

test('can use the component keyword in its layout', function() {
expect(1);
var component = this.subject({
colors: ['red', 'green', 'blue'],
layout: Ember.Handlebars.compile("{{component 'x-foo'}}")
});
this.render();
equal(component._state, 'inDOM');
});

test('clears out views from test to test', function() {
expect(1);
Expand Down

0 comments on commit ad1523e

Please sign in to comment.