Innovenergy_trunk/frontend/node_modules/testcafe/lib/utils/get-browser.js

10 lines
1.6 KiB
JavaScript

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const lodash_1 = require("lodash");
function getBrowser(browserConnection) {
const { browserInfo: { parsedUserAgent, alias } } = browserConnection;
return (0, lodash_1.assign)({}, parsedUserAgent, { alias, headless: browserConnection.isHeadlessBrowser() });
}
exports.default = getBrowser;
module.exports = exports.default;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZ2V0LWJyb3dzZXIuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi9zcmMvdXRpbHMvZ2V0LWJyb3dzZXIudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7QUFBQSxtQ0FBZ0M7QUFTaEMsU0FBd0IsVUFBVSxDQUFFLGlCQUFvQztJQUNwRSxNQUFNLEVBQUUsV0FBVyxFQUFFLEVBQUUsZUFBZSxFQUFFLEtBQUssRUFBRSxFQUFFLEdBQUcsaUJBQWlCLENBQUM7SUFFdEUsT0FBTyxJQUFBLGVBQU0sRUFBQyxFQUFFLEVBQUUsZUFBZSxFQUFFLEVBQUUsS0FBSyxFQUFFLFFBQVEsRUFBRSxpQkFBaUIsQ0FBQyxpQkFBaUIsRUFBRSxFQUFFLENBQUMsQ0FBQztBQUNuRyxDQUFDO0FBSkQsNkJBSUMiLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgeyBhc3NpZ24gfSBmcm9tICdsb2Rhc2gnO1xuaW1wb3J0IHsgUGFyc2VkVXNlckFnZW50IH0gZnJvbSAnLi9wYXJzZS11c2VyLWFnZW50JztcbmltcG9ydCBCcm93c2VyQ29ubmVjdGlvbiBmcm9tICcuLi9icm93c2VyL2Nvbm5lY3Rpb24nO1xuXG5pbnRlcmZhY2UgQnJvd3NlciBleHRlbmRzIFBhcnNlZFVzZXJBZ2VudCB7XG4gICAgYWxpYXM6IHN0cmluZztcbiA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