如何使用selenium webdriver声明多行警报文本?

时间:2013-05-22 13:31:12

标签: selenium-webdriver

请查找我的示例警报代码:

alert('passed properties:\n' + passString +  ' \n\n Failed Properties:\n' + failString );

我的硒代码:

Alert alert = null;
alert = driver.switchTo.alert();
Assert.assertEquals("passed properties:\n<passString> \n\n Failed Properties:\n <failString>",alert.getText());

0 个答案:

没有答案