Selenium RC:如何使用多个浏览器启动交互式测试

时间:2010-05-14 17:39:40

标签: ruby selenium selenium-rc

我想自动化这种情况。 UserA为UserB分配项目,UserB获取警报消息。为了做到这一点,我希望使用不同的帐户启动两个不同的浏览器来测试此交互。有可能这样做吗?如果是,怎么样?

1 个答案:

答案 0 :(得分:3)

在我的示例代码中已经回答了这个问题:http://stackoverflow.com/questions/213430/selenium-rc-run-tests-in-multiple-browsers-automatically。

firefox = Selenium::SeleniumDriver.new("localhost", 4444, '*firefox', "http://localhost:3000", 10000)
ie = Selenium::SeleniumDriver.new("localhost", 4444, '*iexpore', "http://localhost:3000", 10000)

然后按照您喜欢的方式在不同的浏览器中运行命令。