• 博客园logo
  • 会员
  • 众包
  • 新闻
  • 博问
  • 闪存
  • 赞助商
  • HarmonyOS
  • Chat2DB
    • 搜索
      所有博客
    • 搜索
      当前博客
  • 写随笔 我的博客 短消息 简洁模式
    用户头像
    我的博客 我的园子 账号设置 会员中心 简洁模式 ... 退出登录
    注册 登录
pealy
博客园    首页    新随笔    联系   管理    订阅  订阅

WebDriver In .Net

Step1:Create Unit Test Project With VS:

Step2:Add WebDriver Referene:
Step3:Initial FireFoxWebDriver
Step4:Simulator Search "Selenium in .net" in BaiDu
            driver.Navigate().GoToUrl("http://baidu.com");
            driver.FindElement(By.Id("wd")).SendKeys("Selenium in .Net");
            driver.FindElement(By.Id("su")).Click();
Step5:Add geckodriver.exe to directory which app run, and firefox.exe path to Enivironment Path
Step6: Run Unit Test:OK
 
It's can also use Chrome or Internet Explorer, and the SimpleBrowser seems can test fast and in memory.
https://github.com/SimpleBrowserDotNet/SimpleBrowser.WebDriver
posted @ 2017-01-18 14:53  jessicaxia  阅读(283)  评论(0)    收藏  举报
刷新页面返回顶部
博客园  ©  2004-2025
浙公网安备 33010602011771号 浙ICP备2021040463号-3