@applitools/spec-driver-selenium 1.3.13 → 1.3.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/spec-driver.js +10 -8
- package/package.json +3 -3
- package/types/index.d.ts +1 -1
package/dist/spec-driver.js
CHANGED
|
@@ -23,7 +23,7 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
23
23
|
return result;
|
|
24
24
|
};
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
-
exports.build = exports.performAction = exports.getElementText = exports.getElementAttribute = exports.getElementRegion = exports.getOrientation = exports.setOrientation = exports.
|
|
26
|
+
exports.build = exports.performAction = exports.getElementText = exports.getElementAttribute = exports.getElementRegion = exports.getOrientation = exports.setOrientation = exports.getSystemBars = exports.waitUntilDisplayed = exports.scrollIntoView = exports.type = exports.hover = exports.click = exports.takeScreenshot = exports.visit = exports.getUrl = exports.getTitle = exports.getCapabilities = exports.getDriverInfo = exports.getCookies = exports.setWindowSize = exports.getWindowSize = exports.waitForSelector = exports.findElements = exports.findElement = exports.childContext = exports.parentContext = exports.mainContext = exports.executeScript = exports.isEqualElements = exports.isStaleElementError = exports.untransformSelector = exports.transformSelector = exports.transformDriver = exports.isSelector = exports.isElement = exports.isDriver = void 0;
|
|
27
27
|
const Selenium = __importStar(require("selenium-webdriver"));
|
|
28
28
|
const utils = __importStar(require("@applitools/utils"));
|
|
29
29
|
// #region HELPERS
|
|
@@ -315,14 +315,14 @@ async function waitUntilDisplayed(driver, selector, timeout) {
|
|
|
315
315
|
exports.waitUntilDisplayed = waitUntilDisplayed;
|
|
316
316
|
// #endregion
|
|
317
317
|
// #region MOBILE COMMANDS
|
|
318
|
-
async function
|
|
318
|
+
async function getSystemBars(driver) {
|
|
319
319
|
const { Command } = require('selenium-webdriver/lib/command');
|
|
320
320
|
const getSystemBarsCommand = new Command('getSystemBars');
|
|
321
321
|
return process.env.APPLITOOLS_SELENIUM_MAJOR_VERSION === '3'
|
|
322
322
|
? await driver.schedule(getSystemBarsCommand)
|
|
323
323
|
: await driver.execute(getSystemBarsCommand);
|
|
324
324
|
}
|
|
325
|
-
exports.
|
|
325
|
+
exports.getSystemBars = getSystemBars;
|
|
326
326
|
async function setOrientation(driver, orientation) {
|
|
327
327
|
const { Command } = require('selenium-webdriver/lib/command');
|
|
328
328
|
const setOrientationCommand = new Command('setOrientation').setParameters({ orientation });
|
|
@@ -399,11 +399,13 @@ async function build({ selenium, ...env }) {
|
|
|
399
399
|
desiredCapabilities[browserOptionsName] = browserOptions;
|
|
400
400
|
}
|
|
401
401
|
}
|
|
402
|
-
if (
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
402
|
+
if (browser === 'chrome') {
|
|
403
|
+
if (appium) {
|
|
404
|
+
desiredCapabilities['appium:chromeOptions'] = { w3c: false, ...desiredCapabilities['appium:chromeOptions'] };
|
|
405
|
+
}
|
|
406
|
+
else if (process.env.APPLITOOLS_SELENIUM_MAJOR_VERSION === '3') {
|
|
407
|
+
desiredCapabilities['goog:chromeOptions'] = { w3c: false, ...desiredCapabilities['goog:chromeOptions'] };
|
|
408
|
+
}
|
|
407
409
|
}
|
|
408
410
|
const builder = new Builder().withCapabilities(desiredCapabilities);
|
|
409
411
|
if (url && !attach)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@applitools/spec-driver-selenium",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.16",
|
|
4
4
|
"keywords": [
|
|
5
5
|
"selenium",
|
|
6
6
|
"selenium-webdriver",
|
|
@@ -62,14 +62,14 @@
|
|
|
62
62
|
}
|
|
63
63
|
},
|
|
64
64
|
"dependencies": {
|
|
65
|
-
"@applitools/types": "1.5.
|
|
65
|
+
"@applitools/types": "1.5.7",
|
|
66
66
|
"@applitools/utils": "1.3.10"
|
|
67
67
|
},
|
|
68
68
|
"devDependencies": {
|
|
69
69
|
"@applitools/api-extractor": "^1.2.9",
|
|
70
70
|
"@applitools/bongo": "2.1.6",
|
|
71
71
|
"@applitools/scripts": "1.1.0",
|
|
72
|
-
"@applitools/test-utils": "1.3
|
|
72
|
+
"@applitools/test-utils": "1.4.3",
|
|
73
73
|
"@types/mocha": "^9.1.1",
|
|
74
74
|
"@types/node": "12",
|
|
75
75
|
"@types/selenium-webdriver": "^4.1.1",
|
package/types/index.d.ts
CHANGED
|
@@ -29,7 +29,7 @@ export function hover(driver: Driver, element: Element | Selector): Promise<void
|
|
|
29
29
|
export function type(driver: Driver, element: Element | Selector, keys: string): Promise<void>;
|
|
30
30
|
export function scrollIntoView(driver: Driver, element: Element | Selector, align: boolean): Promise<void>;
|
|
31
31
|
export function waitUntilDisplayed(driver: Driver, selector: Selector, timeout: number): Promise<void>;
|
|
32
|
-
export function
|
|
32
|
+
export function getSystemBars(driver: Driver): Promise<{ statusBar: {
|
|
33
33
|
visible: boolean;
|
|
34
34
|
x: number;
|
|
35
35
|
y: number;
|