import {
  moduleForComponent,
  test
} from 'ember-qunit';

moduleForComponent('md-text', 'MdTextComponent', {
  // specify the other units that are required for this test
  // needs: ['component:foo', 'helper:bar']
});

test('it renders', function() {
  expect(2);

  // creates the component instance
  var component = this.subject();
  equal(component._state, 'preRender');

  // appends the component to the page
  this.append();
  equal(component._state, 'inDOM');
});

@@ -1,8 +1,36 @@
+import Ember from 'ember';%0A%0A
 import %7B
@@ -30,16 +30,16 @@
 mport %7B%0A
-
   module
@@ -279,22 +279,8 @@
 ) %7B%0A
-  expect(2);%0A%0A
   //
@@ -438,24 +438,24 @@
 s.append();%0A
-
   equal(comp
@@ -478,12 +478,439 @@
 nDOM');%0A%7D);%0A
+%0Atest('it displays text', function() %7B%0A  var component = this.subject();%0A  component.set('text', '# Markdown is fun');%0A%0A  var $component = this.append();%0A  equal($component.text().trim(), 'Markdown is fun');%0A%7D);%0A%0Atest('it properly parses the markdown', function() %7B%0A  var component = this.subject();%0A  component.set('text', '# Markdown is fun');%0A%0A  var $component = this.append();%0A  equal($component.find('h1').length, 1);%0A%7D);%0A

Add component tests