Driver Binaries
To run automation based on the WebDriver protocol you need to have browser drivers set up that translate the automation commands and are able execute them in the browser. With WebdriverIO v8.14
and above there is no need to manually download and setup any browser drivers anymore as this is handled by WebdriverIO. You only need to have a browser installed, that's it!
The following describes how you can still set up each driver individually. आप awesome-selenium
रीडमे में सभी ड्राइवर ों के साथ एक सूची पा सकते हैं।
If you are looking to set up mobile and other UI platforms, have a look into our Appium Setup guide.
क्रोमड्राइवर
क्रोम को स्वचालित करने के लिए आप Chromedriver को सीधे प्रोजेक्ट वेबसाइट या NPM पैकेज के माध्यम से डाउनलोड कर सकते हैं:
- npm
- Yarn
- pnpm
npm install -g chromedriver
yarn global add chromedriver
pnpm add -g chromedriver
इसके बाद आप इसे शुरू कर सकते हैं:
chromedriver --port=4444 --verbose
गेकोड्राइवर
फ़ायरफ़ॉक्स को स्वचालित करने के लिए अपने पर्यावरण के लिए geckodriver
का नवीनतम संस्करण डाउनलोड करें और इसे अपनी प्रोजेक्ट निर्देशिका में अनपैक करें:
- NPM
- Curl
- Brew
- Windows (64 bit / Chocolatey)
- Windows (64 bit / Powershell) DevTools
- npm
- Yarn
- pnpm
npm install geckodriver
yarn add geckodriver
pnpm add geckodriver
Linux:
curl -L https://github.com/mozilla/geckodriver/releases/download/v0.24.0/geckodriver-v0.24.0-linux64.tar.gz | tar xz
MacOS (64 bit):
curl -L https://github.com/mozilla/geckodriver/releases/download/v0.24.0/geckodriver-v0.24.0-macos.tar.gz | tar xz
brew install geckodriver
choco install selenium-gecko-driver
# Run as privileged session. Right-click and set 'Run as Administrator'
# Use geckodriver-v0.24.0-win32.zip for 32 bit Windows
$url = "https://github.com/mozilla/geckodriver/releases/download/v0.24.0/geckodriver-v0.24.0-win64.zip"
$output = "geckodriver.zip" # will drop into current directory unless defined otherwise
$unzipped_file = "geckodriver" # will unzip to this folder name
# By default, Powershell uses TLS 1.0 the site security requires TLS 1.2
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
# Downloads Geckodriver
Invoke-WebRequest -Uri $url -OutFile $output
# Unzip Geckodriver
Expand-Archive $output -DestinationPath $unzipped_file
cd $unzipped_file
# Globally Set Geckodriver to PATH
[System.Environment]::SetEnvironmentVariable("PATH", "$Env:Path;$pwd\geckodriver.exe", [System.EnvironmentVariableTarget]::Machine)
Note: Other geckodriver
releases are available here. After download you can start the driver via:
/path/to/binary/geckodriver --port 4444
Edgedriver
You can download the driver for Microsoft Edge on the project website or as NPM package via:
npm install -g edgedriver
edgedriver --version # prints: Microsoft Edge WebDriver 115.0.1901.203 (a5a2b1779bcfe71f081bc9104cca968d420a89ac)
Safaridriver
सफ़ारीड्राइवर आपके MacOS पर पहले से इंस्टॉल आता है और इसके द्वारा सीधे शुरू किया जा सकता है:
सफारीड्राइवर -पी 4444