sefiutils 1.0.30 → 1.0.31
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/lib/globalSetup.d.ts.map +1 -1
- package/lib/globalSetup.js +6 -4
- package/lib/globalSetup.js.map +1 -1
- package/package.json +1 -1
package/lib/globalSetup.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"globalSetup.d.ts","sourceRoot":"","sources":["../src/globalSetup.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"globalSetup.d.ts","sourceRoot":"","sources":["../src/globalSetup.ts"],"names":[],"mappings":"AAEA,OAAO,CAAC,MAAM,CAAC;IACX,IAAI,MAAM,EAAE,GAAG,CAAC;CAEnB;AACD;;;;;;;;;;;;;;;;GAgBG;AACH,wBAA8B,gBAAgB,kBAc7C"}
|
package/lib/globalSetup.js
CHANGED
|
@@ -32,6 +32,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
32
32
|
});
|
|
33
33
|
};
|
|
34
34
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
35
|
+
const log_1 = require("./log");
|
|
35
36
|
/**
|
|
36
37
|
* This function is called by Jest once before all tests are executed.
|
|
37
38
|
* In order to get called, it must be referenced in the jest configuration file:
|
|
@@ -52,7 +53,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
52
53
|
function setGlobalObjects() {
|
|
53
54
|
return __awaiter(this, void 0, void 0, function* () {
|
|
54
55
|
const browser = process.env.BROWSER || "remote";
|
|
55
|
-
|
|
56
|
+
(0, log_1.verbose)(`Global Setup: Use browser: ${browser}`);
|
|
56
57
|
try {
|
|
57
58
|
if (browser === "remote") {
|
|
58
59
|
yield setUpSeleniumServer();
|
|
@@ -70,14 +71,15 @@ function setGlobalObjects() {
|
|
|
70
71
|
exports.default = setGlobalObjects;
|
|
71
72
|
function setUpSeleniumServer() {
|
|
72
73
|
return __awaiter(this, void 0, void 0, function* () {
|
|
74
|
+
(0, log_1.debug)("Dynamic import of selenium-webdriver/remote and selenium-server-standalone-jar");
|
|
73
75
|
const remote = yield Promise.resolve().then(() => __importStar(require("selenium-webdriver/remote")));
|
|
74
76
|
//@ts-ignore
|
|
75
77
|
const jar = yield Promise.resolve().then(() => __importStar(require('selenium-server-standalone-jar')));
|
|
76
78
|
if (globalThis.server) {
|
|
77
79
|
yield globalThis.server.kill();
|
|
78
|
-
|
|
80
|
+
(0, log_1.verbose)("`Server killed before starting again");
|
|
79
81
|
}
|
|
80
|
-
|
|
82
|
+
(0, log_1.debug)(() => `Load selenium server from ${jar.path}, SE_NODE_MAX_SESSIONS=4, SE_NODE_OVERRIDE_MAX_SESSIONS=true`);
|
|
81
83
|
const s = new remote.SeleniumServer(jar.path, {
|
|
82
84
|
port: 4444,
|
|
83
85
|
env: Object.assign(Object.assign({}, process.env), { "SE_NODE_MAX_SESSIONS": "4", "SE_NODE_OVERRIDE_MAX_SESSIONS": "true" })
|
|
@@ -85,7 +87,7 @@ function setUpSeleniumServer() {
|
|
|
85
87
|
const address = yield s.start(3000);
|
|
86
88
|
globalThis.server = s;
|
|
87
89
|
// const address = await globalThis.server.address()
|
|
88
|
-
|
|
90
|
+
(0, log_1.debug)(() => `Selenium server started at: ${address}`);
|
|
89
91
|
});
|
|
90
92
|
}
|
|
91
93
|
//# sourceMappingURL=globalSetup.js.map
|
package/lib/globalSetup.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"globalSetup.js","sourceRoot":"","sources":["../src/globalSetup.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"globalSetup.js","sourceRoot":"","sources":["../src/globalSetup.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,+BAAuC;AAMvC;;;;;;;;;;;;;;;;GAgBG;AACH,SAA8B,gBAAgB;;QAC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