Blank.js在Ember-cli中无法与qunit一起使用 [英] blanket.js not working with qunit in Ember-cli

查看:77
本文介绍了Blank.js在Ember-cli中无法与qunit一起使用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在我的Ember-Cli应用程序中运行带有qunit的毯子-我想避免仅出于此目的添加咕unt声

I would like to run blanket.js with qunit in my Ember-Cli app - I would like to avoid adding in grunt for only this purpose

尝试使用npm install --save-dev一揽子(将其放入node_modules目录中)
,然后将以下内容置于我的index.html中(来自测试目录)

Tried to use npm install --save-dev blanket ( putting it in the node_modules dir ) and then putting the following in my index.html ( from my test dir )

 <script>
  window.CioMobileENV = {{ENV}};
  window.EmberENV = window.CioMobileENV.EmberENV;
  debugger;
</script>
<script src="assets/qunit.js"></script>
<script src="assets/qunit-notifications.js"></script>
<script src="blanket.js"></script>
<script src="assets/vendor.js"></script>
<script src="assets/cio-mobile.js" data-cover></script>
<script src="testem.js"></script>
<script>
  require('cio-mobile/tests/test-helper');
</script>
<script src="assets/test-loader.js"></script>

在运行ember服务器后,在浏览器中转到/ tests-测试运行但在控制台中看到未找到blank.js

after running ember server and in the browser going to /tests - the test run but in the console I see that blanket.js is not found

我还尝试了类似的方法,即使用凉亭安装毯子(因此在供应商目录中)
给出了相同的结果。

I also tried a similar approach using bower install blanket ( so in the vender dir ) this gave the same result.

我也尝试过明确地放置路径-仍然找不到Blank.js

I also tried putting in the path explicitly - and still blanket.js is not found

任何帮助都会太好了!

any help would be great!

推荐答案

该工具最近已发布: ember-cli-blanket 。安装非常简单,只要按照说明进行即可。

This tool has recently been released: ember-cli-blanket. Installation is as simple as what the instructions state.

尽管如此,我还是尝试使用它,但没有得到准确的覆盖率报告。但这可能是用户错误。

For what it's worth though, I've tried using this, and i'm not getting accurate coverage reports. It's possible it is user error though.

这篇关于Blank.js在Ember-cli中无法与qunit一起使用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆