xiaozefeng/ubuntu-guide

Selunium 自动化

Opened this issue · 0 comments

Selenium 自动化

  1. install browser ( google-chrome or chromium)
  2. download webdriver : https://sites.google.com/a/chromium.org/chromedriver/downloads
    • unzip it
    • add to path : sudo ln -s /path/to/webdriver/chromedriver /usr/local/bin/chromedriver

Nodes: select suitable driver

  1. open the browser
  2. setttings -> about

Python Usage

  1. pip install selenium
  2. wite code: https://blog.csdn.net/a464057216/article/details/52717464
  3. run: python3 xx.py

Reference

https://www.selenium.dev/documentation/en/getting_started/

Other Automation Tool

puppeteer: https://github.com/puppeteer/puppeteer