由于Seleniumc#中不提供FindElements.IsEmpty(),因此我不得不使用selenium。基本上登录后,我需要检查取消按钮是否存在于DOM上。如果是,那么我们必须启动点击操作。System.Collections.Generic;using System.Text;using OpenQA.Selenium;
using OpenQA.Selenium.Suppo
我试图使用Selenium的Xpath功能来找到一组元素。我在FireFox上使用了FireFox来创建和测试我想出来的Xpath,它工作得很好,但是当我在使用Selenium的c#测试中使用Xpath时,就不会返回任何内容。_driver.FindElements(By.XPath("//div[@class='context-menu-item' and descendant::d