我正在尝试测试我的多人网络游戏,我需要同时运行2个游戏实例,而且我不确定如何在单独的浏览器中同时运行它们。他是我测试的代码;
When(/^I navigate to the multiplayer game page$/) do
When (/^I click to play game$/) do
play = @browser.iframe(:id , 'iconsole-plugin-session_iframe__').button(:id , 'play_game_form_button')
Watir::Wait.for_condition(10 , 2 , "Waiting to see play button") {
puts play.present?
}
play.click
end
play.click
end