ember-cli测试无法加载多个需求

时间:2014-11-12 20:08:26

标签: ember.js ember-cli

我使用的是ember-cli v0.0.44

这是我的测试:

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

moduleFor('controller:cpe-admin', 'CpeAdminController', {
  needs: [ 'controller:application', 'controller:cpe-vendor-summary' ]
});

test('it exists', function() {
  var controller = this.subject();
  ok(controller);
});

以下是运行命令ember test时产生的错误:

not ok 115 PhantomJS 1.9 - CpeAdminController: it exists
    ---
        actual: >
            null
        message: >
            Died on test #1     at http://localhost:7357/assets/test-support.js:412
                at test (http://localhost:7357/assets/test-support.js:278)
                at :17
                at http://localhost:7357/assets/vendor.js:70
                at http://localhost:7357/assets/test-loader.js:14: <(subclass of Ember.Controller):ember286> needs [ controller:cpeVendorSummary ] but it could not be found

文件app / controller / cpe-vendor-summary.js存在于我的项目中。

我做错了什么?

0 个答案:

没有答案