f# - 如何使Canopy的Live HtmlReporter工作?

标签 f# canopy-web-testing

我正在演示演示Canopy的演示,并且正在尝试使LiveHtmlReporter正常工作,但没有成功。到目前为止,我已经能够打开显示模板的浏览器并将报告保存到磁盘,但是报告永远不会随着测试运行的结果进行更新。浏览器和保存的报告都包含默认的0 Passed 0 Failed 0 Todo 0 Skipped。控制台运行器显示

0 minutes 3 seconds to execute
2 passed
0 failed
Not saving report
Not saving report


我有以下代码

open types
open configuration
open reporters

reporter <- new LiveHtmlReporter(Firefox) :> IReporter

let liveHtmlReporter = reporter :?> LiveHtmlReporter
liveHtmlReporter.reportTemplateUrl <- @"http://localhost:56295/content/reporttemplate.html"
liveHtmlReporter.saveReportHtml @"C:\Code\CanopyDemo\" "report"

// Code for actual tests here 


我认为我缺少一些简单的东西,但是我对Canopy或F#尚不熟悉,还无法发现我所缺少的东西。

最佳答案

There is similar question

reporter <- new LiveHtmlReporter(Chrome, configuration.chromeDir) :> IReporter
let liveHtmlReporter = reporter :?> LiveHtmlReporter
liveHtmlReporter.reportPath <- Some "reports/AutomationResults"

关于f# - 如何使Canopy的Live HtmlReporter工作?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/24511062/

相关文章:

f# - 如何将 Canopy 与 Browserstack 结合使用

asp.net - 如何更改 F# Canopy UI 测试脚本中的下拉菜单

events - 什么是 F# 相当于 C# "public event "

f# - 如何让 Canopy 的 Live HtmlReporter 工作?

f# - 如何查看程序集中的类型提供程序

c# - F# 中的字典推导式(?)(从 C# 转换)

F# Canopy - 生成随机字母和/或数字并在变量中使用

F# Canopy - 如何使用 "context"测试?

F# 关键字 'Some'

c# - 如何在 F# 中实现具有方法返回任务(非泛型)的接口(interface)