-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
/
Copy pathusage.spec.js
32 lines (24 loc) · 906 Bytes
/
usage.spec.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
const Chrome = require('selenium-webdriver/chrome');
const {Browser, Builder} = require("selenium-webdriver");
const options = new Chrome.Options();
describe('Usage Test', function () {
it('After Selenium Manager', async function () {
let driver = new Builder()
.forBrowser(Browser.CHROME)
.build();
await driver.get('https://www.selenium.dev/selenium/web/blank.html');
await driver.quit();
});
it('Before Selenium Manager', async function () {
let driverPath = paths.driverPath;
let browserPath = paths.browserPath;
options.setChromeBinaryPath(browserPath)
let service = new Chrome.ServiceBuilder().setPath(driverPath)
let driver = new Builder()
.forBrowser(Browser.CHROME)
.setChromeService(service)
.build();
await driver.get('https://www.selenium.dev/selenium/web/blank.html');
await driver.quit();
});
});