Selenium and Mocha
Explore the step-by-step process of installing Selenium WebDriver and Mocha using npm in Node.js. Understand how to create and configure a package.json file to manage dependencies, enabling you to set up a testing environment for Selenium automation scripts.
We'll cover the following...
We'll cover the following...
Installing Selenium
By default, Node.js scripts load dependent (npm) packages installed locally, i.e., the packages are installed under the directory where the scripts are located.
> cd YOUR_SCRIPT_DIRECTORY
> npm install selenium-webdriver@3.6.0
When it is done, you will see output like below:
+ selenium-webdriver@3.6.0
At the time of writing, the latest release of Selenium WebDriver for JavaScript is 4.0.0-alpha.7, which is a pre-release version (and I found some issues with it). For some unknown ...