是否有可能运行codeD UI测试,而无需通过远程桌面连接? [英] Is it possible to run Coded UI tests without having to connect via remote desktop?
问题描述
我试图自动化codeD UI测试。
I'm attempting to automate Coded UI tests.
我的测试控制器推出一个远程测试服务器上的测试,这是我通过远程桌面连接正常访问。
My test controller launches the tests on a remote test server, which I normally access via a Remote Desktop connection.
有没有可能,而无需通过远程桌面连接运行codeD UI测试?
Is it possible to run the Coded UI tests without having to connect via remote desktop?
目前,在测试时,我通过远程桌面连接了只运行,该窗口必须打开。当我关闭远程桌面会话,测试不运行。
Currently, the tests only run when I have connected via Remote Desktop, and the window must be open. When I close the Remote Desktop session, the tests do not run.
如果这是不可能的运行没有远程桌面codeD UI测试,我怎么可以自动通过远程桌面连接?
If it isn't possible to run coded UI tests without remote desktop, how can I automate connecting via remote desktop?
感谢
推荐答案
最简单的解决这个问题很简单就是在我的测试环境中启用自动登录(有很多种,这取决于操作系统这样的方式)。
The easiest solution to this problem was simply to enable auto-logon on my test environment (there are a variety of ways of doing this depending on OS).
使用自动登录启用后,当我重新启动测试环境(使用shutdown.exe的/ R命令,它可以编写脚本),测试环境负荷备份与活动,登录会话,所以测试可以成功运行。
With auto-logon enabled, when I restart the test environment (using the 'shutdown.exe /r' command, which can be scripted), the test environment loads back up with an active, logged on session, and so the tests can run successfully.
有关我的夜间测试自动化,我启用了自动登录在我的测试环境,并计划在测试执行之前重新启动。
For my nightly test automation, I enabled auto-logon on my test environment and scheduled a restart prior to test execution.
我已经用这种方法没有任何问题 - 这意味着我没有通过远程桌面连接。
I have had no issues with this method - and it means I don't have to connect via Remote Desktop.
这篇关于是否有可能运行codeD UI测试,而无需通过远程桌面连接?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!