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

yxchun

  • 博客园
  • 联系
  • 订阅
  • 管理

公告

2023年12月11日

java-selenium 使用固定版本chrome浏览器和chromedriver,解决chrome自动升级无法与Chromedriver匹配问题

摘要: 1、获取Google chrome、chromedriver 地址:https://googlechromelabs.github.io/chrome-for-testing/ 2、将2个压缩包解压,存放到固定目录 比如我的chromedriver位置为:D:\file\jar\chromeDriv 阅读全文

posted @ 2023-12-11 13:57 yxchun 阅读(1578) 评论(0) 推荐(0)

java-selenium 启动时出现 Invalid Status code=403 text=Forbidden

摘要: 加上 chromeOptions.addArguments("--remote-allow-origins=*"); 即可 ChromeOptions chromeOptions = new ChromeOptions(); // 防止403 chromeOptions.addArguments(" 阅读全文

posted @ 2023-12-11 13:44 yxchun 阅读(309) 评论(0) 推荐(0)

java-selenium 操作页面时免登录,记录用户的登录信息

摘要: 利用 ChromeOptions ,启动浏览器时设置用户数据存放目录,下次启动程序时,继续加载这个目录 // chrome 浏览器数据存储目录位置 String userData="--user-data-dir=C:\\Users\\AppData\\Local\\Google\\Chrome\\ 阅读全文

posted @ 2023-12-11 13:43 yxchun 阅读(277) 评论(0) 推荐(1)

抖音自动化-实现给特定用户发私信 (java-selenium)

摘要: 重点: 打开新的窗口后,driver发生了变化,不能再用之前的driver;可以通过窗口句柄,跳转到新页面 // 页面跳转,driver再次发生变化;(既 :重新打开一个浏览器窗口后,driver发生了变化,不能使用原先窗口的driver) for (String windowHandle : dr 阅读全文

posted @ 2023-12-11 13:39 yxchun 阅读(955) 评论(2) 推荐(0)

 
博客园  ©  2004-2025
浙公网安备 33010602011771号 浙ICP备2021040463号-3