在 TeamCity 上运行 Watin

发布于 2024-07-13 01:12:34 字数 181 浏览 6 评论 0原文

我尝试通过 TeamCity 运行简单的 Watin 测试,但 Internet Explorer 窗口从未像通常通过 CruiseControl 那样显示。

我收到错误消息,提示找不到文本字段,因此某些内容正在运行。 但没有窗户我就看不到什么。

我需要对 TeamCity 服务器的设置进行特定更改吗?

I'm trying to run a simple Watin test through TeamCity but the Internet Explorer window is never shown as is usually is via CruiseControl.

I get an error that it can't find a text field so something is running. But i can't see what without the window.

Is there a specific change to the setup of TeamCity server that I need to do?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(5

沧桑㈠ 2024-07-20 01:12:35

另一个论坛上找到此内容

所有积分均归 Matt Baker

供任何尝试运行 WatiN 的人将来参考使用 TeamCity 自动测试。 您必须使用 \bin\agent.bat start 启动构建代理,而不是作为服务。 WatiN 需要完整的 UI 才能正确执行,并且它不会将此环境作为服务获取。 我希望这对其他人来说更容易!

Found this on another forum

All credits go to Matt Baker

For future reference to anyone who attempts to run WatiN tests automatically using TeamCity. You must start your build agent using \bin\agent.bat start and NOT as a service. WatiN requires a full UI to execute properly and it doesn't get this environment as a service. I hope this makes it easier for other people!

各空 2024-07-20 01:12:35

如果您安装为服务,请确保停止并禁用它。 然后,使用以下内容创建一个 .bat 文件

C:
cd teamcity\buildagent\bin\
agent.bat start

现在只需在启动文件夹中创建此批处理文件的快捷方式即可!

If you installed as a service, make sure to stop it and disable it. Then, create a .bat file with the following

C:
cd teamcity\buildagent\bin\
agent.bat start

Now just create a shortcut in your start up folder to this batch file!

一枫情书 2024-07-20 01:12:35
  1. 停止代理服务。 从控制台执行命令:net stop TCBuildAgent。
  2. 从控制台运行 c:\teamcity\buildagent\bin\agent.bat
    开始(取决于你的团队所在城市
    安装路径)
  1. Stop agent service. execute command: net stop TCBuildAgent from console.
  2. Run from console c:\teamcity\buildagent\bin\agent.bat
    start (depending on your teamcity
    installation path)
寄与心 2024-07-20 01:12:35

请尝试这个简单的解决方案:
转到服务,编辑服务的属性,选择登录选项卡,然后选中带有标签的框:“允许服务与桌面交互”。

在竹子里为我工作。

干杯,
佩德罗·莫莱罗

Please try this simple solution:
Go to services, edit the properties of your service, select the LogOn Tab, and check the box with the label: "Allow service to interact with desktop".

Worked for me in bamboo.

Cheers,
Pedro O Moleiro

眼趣 2024-07-20 01:12:34

在 Teamcity Agent 的服务属性窗口 (services.msc) 的“帐户”选项卡下,选中“允许服务与桌面交互”,这将允许本地服务帐户生成 Internet Explorer。 但您肯定会遇到其他问题,例如 cookie 阻止、密码保存等。因此,以本地服务身份登录并修复这些问题。

最简单的方法是使用 psexec (http:// /technet.microsoft.com/en-us/sysinternals/bb897553.aspx),调用 psexec -i -s cmd.exe 生成一个以本地帐户运行的 cmd,然后启动 Internet浏览器设置一切(IE 中本地帐户的隐私设置非常高)。

Under Account tab on the Teamcity Agent's Service property window (services.msc), check "Allow service to interact with desktop", that will allow local service account to spawn internet explorer. But you will most certainly get stuck with other stuff, like cookie blocking, password saving etc. so login as local service and fix those stuff.

Easiest way to do that is with psexec (http://technet.microsoft.com/en-us/sysinternals/bb897553.aspx), call psexec -i -s cmd.exe so spawn a cmd running as local account, then start internet explorer at setup everything up (the privacy settings in IE for local account is extremely high).

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文