-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
/
Copy pathpageLoading.spec.js
37 lines (27 loc) · 1.19 KB
/
pageLoading.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
33
34
35
36
37
const { Capabilities } = require('selenium-webdriver');
const { suite } = require('selenium-webdriver/testing');
suite(function(env) {
describe('Page loading strategies', function() {
it('Navigate using eager page loading strategy', async function() {
let caps = new Capabilities();
caps.setPageLoadStrategy("eager");
let driver = await env.builder().withCapabilities(caps).build();
await driver.get('https://www.google.com');
driver.quit();
});
it('Navigate using none page loading strategy', async function() {
let caps = new Capabilities();
caps.setPageLoadStrategy("none");
let driver = await env.builder().withCapabilities(caps).build();
await driver.get('https://www.google.com');
driver.quit();
});
it('Navigate using normal page loading strategy', async function() {
let caps = new Capabilities();
caps.setPageLoadStrategy("normal");
let driver = await env.builder().withCapabilities(caps).build();
await driver.get('https://www.google.com');
driver.quit();
});
});
});