gpt4 book ai didi

selenium-rc - 使用 Selenium RC 购买 Paypal-Sandbox

转载 作者:行者123 更新时间:2023-12-04 02:39:57 27 4
gpt4 key购买 nike

我正在尝试使用 Selenium RC (Java) 在 Paypal-Sandbox 上购买东西,但它不起作用。

我用 Selenium IDE (Firefox AddOn) 试过了,它确实有效。我更改了 View 并复制了 JUnit 4 代码,但它仍然不起作用。

问题出在带有单选按钮“payment_type_paypal”的部分。它以某种方式在 RC 中不起作用(未选中单选按钮)。有人有类似的经历和/或解决了这个问题吗?

登录developer.paypal.com并进入首页后...

//linking homepage

selenium.click("legalTerms");

selenium.click("pay");

selenium.waitForPageToLoad("30000");

//leaving homepage and switching to paypal

selenium.click("payment_type_paypal"); // <===== point of error

selenium.type("login_email",username);

selenium.type("login_password",pw);

谢谢 :)

最佳答案

是我,Krzys。我现在知道问题所在了。这是聚焦正确框架的问题。我无法让它与 Selenium RC 一起工作。

在我的“错误点”之前,您可以使用命令轻松修复 Selenium WebDriver 中的问题:

  driver.switchTo().defaultContent();

关于selenium-rc - 使用 Selenium RC 购买 Paypal-Sandbox,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/6423584/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com