Teamcity 报告器
WebdriverIO Teamcity 报告器使得实时显示测试结果成为可能,并在构建结果页面的测试选项卡上提供测试信息。
安装
npm install wdio-teamcity-reporter --save-dev
有关如何安装 WebdriverIO 的说明可以在这里找到:https://webdriver.io/docs/gettingstarted
配置
在你的 wdio.conf.js 文件中添加报告器:
exports.config = {
// ...
reporters: [
[
'teamcity',
{
captureStandardOutput: false, // optional
flowId: true, // optional
message: '[title]', // optional
}
]
],
// ...
}
选项
captureStandardOutput (boolean)
— 如果为true
,所有在testStarted
和testFinished
消息之间接收的标准输出(和标准错误)消息将被视为测试输出。默认值为false
,假设使用 testStdOut 和 testStdErr 服务消息来报告测试输出。默认false
。flowId (boolean)
— 如果为true
,flowId
属性将添加到 所有消息中。流跟踪对于区分并行运行的单独进程是必要的。默认true
。message (string)
— 为名称属性提供特定格式的可能性。可能的键:[browser]
,[title]
。例如,[browser] / [title]
。默认[title]
。
链接
- Teamcity 关于报告消息的文档参考:https://confluence.jetbrains.com/display/TCD65/Build+Script+Interaction+with+TeamCity
- Teamcity 测试驱动:https://blog.jetbrains.com/teamcity/2019/08/getting-started-with-teamcity-testdrive/
许可证
The MIT License