jeudi 4 février 2016

Unexpected token import in Ember Application

I've installed ember-mocha

Then created a new test under my Ember's tests folder.

/tests/my-test.js

import { describeModule, it } from 'ember-mocha';


let chai = require('chai'),
    expect = chai.should();


describeModule('Companies - List', () => {

  it('should display a list of companies ', () => {
    expect($('tr.companies').to.have.length(2));
  });

});

Not sure why my Ember application isn't resolving the ES6 import directive.

I'm running this in Webstorm. I've already gone to Preferences in Webstorm and made sure that the JavaScript framework is set to ES6. But still it's not resolving that in my test.

Aucun commentaire:

Enregistrer un commentaire