首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >Mocha-casperjs没有创建xunit文件。

Mocha-casperjs没有创建xunit文件。
EN

Stack Overflow用户
提问于 2015-04-20 08:28:24
回答 1查看 172关注 0票数 0

我使用摩卡来运行我的测试。我正在使用命令make test运行我的测试。因此,我的Makefile看起来如下:

Makefile:

代码语言:javascript
运行
复制
test:
    # Clear console log before we start.
    @clear

    # Make sure we are not having too much modules.
    @npm prune

    # Make sure we have the required modules.
    @npm install

    # Clear the console, so we only see the test results.
    @clear

    # Run the test.
    ./node_modules/.bin/mocha-casperjs sample.js --xunit=xmllog.xml

.PHONY: test

但是xmllog.xml从来没有创建过。在运行测试之前,我试着触摸xmllog.xml。我试着在测试中出现错误,以确保跳过失败的测试。我已经对失败的测试进行了评论。但是没有创建xmllog.xml。有人有线索吗?

我正在运行mocha-casperjs版本1.1.0-beta3。

谢谢!

答案:

多亏了@vanadium23 23,我才能解决这个太简单的问题。我混淆了CasperJS本身和mocha-casperjs的文档。他的回答是:

在文档中,没有-xunit这样的选项。相反,您需要使用选项--file=xmllog.xml

谢谢@vanadium23 23

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2015-04-20 08:46:44

在文档中,没有-xunit这样的选项。相反,您需要使用选项--file=xmllog.xml

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/29742729

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档