Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@percy/core

Package Overview
Dependencies
Maintainers
0
Versions
241
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@percy/core - npm Package Compare versions

Comparing version 1.28.8-beta.4 to 1.28.8-beta.6

9

dist/config.js

@@ -12,2 +12,5 @@ // Common config options used in Percy commands

type: 'string'
},
labels: {
type: 'string'
}

@@ -78,2 +81,5 @@ }

},
labels: {
type: 'string'
},
thTestCaseExecutionId: {

@@ -333,2 +339,5 @@ type: 'string'

},
labels: {
$ref: '/config/snapshot#/properties/labels'
},
thTestCaseExecutionId: {

@@ -335,0 +344,0 @@ $ref: '/config/snapshot#/properties/thTestCaseExecutionId'

11

dist/percy.js

@@ -41,2 +41,3 @@ import PercyClient from '@percy/client';

// implies `dryRun`, silent logs, and adds extra api endpoints
labels,
testing,

@@ -73,2 +74,3 @@ // configuration filepath

this.deferUploads = this.skipUploads || !!deferUploads;
this.labels = labels;
this.client = new PercyClient({

@@ -78,3 +80,4 @@ token,

environmentInfo,
config
config,
labels
});

@@ -364,2 +367,8 @@ if (server) this.server = createPercyServer(this, port);

// validate comparison uploads and warn about any errors
// we are having two similar attrs in options: tags & tag
// tags: is used as labels and is string comma-separated like "tag1,tag"
// tag: is comparison-tag used by app-percy & poa and this is used to create a comparison-tag in BE
// its format is object like {name: "", os:"", os_version:"", device:""}
// DO NOT GET CONFUSED!!! :)
if ('tag' in options || 'tiles' in options) {

@@ -366,0 +375,0 @@ var _options$tag;

49

dist/queue.js

@@ -1,11 +0,14 @@

function _classPrivateMethodInitSpec(obj, privateSet) { _checkPrivateRedeclaration(obj, privateSet); privateSet.add(obj); }
function _classPrivateFieldInitSpec(obj, privateMap, value) { _checkPrivateRedeclaration(obj, privateMap); privateMap.set(obj, value); }
function _checkPrivateRedeclaration(obj, privateCollection) { if (privateCollection.has(obj)) { throw new TypeError("Cannot initialize the same private elements twice on an object"); } }
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
function _classPrivateFieldSet(receiver, privateMap, value) { var descriptor = _classExtractFieldDescriptor(receiver, privateMap, "set"); _classApplyDescriptorSet(receiver, descriptor, value); return value; }
function _classApplyDescriptorSet(receiver, descriptor, value) { if (descriptor.set) { descriptor.set.call(receiver, value); } else { if (!descriptor.writable) { throw new TypeError("attempted to set read only private field"); } descriptor.value = value; } }
function _classPrivateMethodGet(receiver, privateSet, fn) { if (!privateSet.has(receiver)) { throw new TypeError("attempted to get private field on non-instance"); } return fn; }
function _classPrivateFieldGet(receiver, privateMap) { var descriptor = _classExtractFieldDescriptor(receiver, privateMap, "get"); return _classApplyDescriptorGet(receiver, descriptor); }
function _classExtractFieldDescriptor(receiver, privateMap, action) { if (!privateMap.has(receiver)) { throw new TypeError("attempted to " + action + " private field on non-instance"); } return privateMap.get(receiver); }
function _classApplyDescriptorGet(receiver, descriptor) { if (descriptor.get) { return descriptor.get.call(receiver); } return descriptor.value; }
function _classPrivateMethodInitSpec(e, a) { _checkPrivateRedeclaration(e, a), a.add(e); }
function _classPrivateFieldInitSpec(e, t, a) { _checkPrivateRedeclaration(e, t), t.set(e, a); }
function _checkPrivateRedeclaration(e, t) { if (t.has(e)) throw new TypeError("Cannot initialize the same private elements twice on an object"); }
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
function _classPrivateFieldSet(e, t, r) { var s = _classPrivateFieldGet2(t, e); return _classApplyDescriptorSet(e, s, r), r; }
function _classApplyDescriptorSet(e, t, l) { if (t.set) t.set.call(e, l);else { if (!t.writable) throw new TypeError("attempted to set read only private field"); t.value = l; } }
function _classPrivateMethodGet(s, a, r) { return _assertClassBrand(a, s), r; }
function _classPrivateFieldGet(e, t) { var r = _classPrivateFieldGet2(t, e); return _classApplyDescriptorGet(e, r); }
function _classPrivateFieldGet2(s, a) { return s.get(_assertClassBrand(s, a)); }
function _assertClassBrand(e, t, n) { if ("function" == typeof e ? e === t : e.has(t)) return arguments.length < 3 ? t : n; throw new TypeError("Private element is not present on this object"); }
function _classApplyDescriptorGet(e, t) { return t.get ? t.get.call(e) : t.value; }
import { yieldFor, generatePromise, AbortController } from './utils.js';

@@ -163,9 +166,11 @@ import logger from '@percy/logger';

// keep track of start and end tasks
// Initialize a starting task or return an existing one.
start() {
var _classPrivateFieldGet2;
var _classPrivateFieldGet3;
_classPrivateFieldGet(this, _start) ?? _classPrivateFieldSet(this, _start, deferred({
readyState: 1
}));
(_classPrivateFieldGet2 = _classPrivateFieldGet(this, _start)).handler ?? (_classPrivateFieldGet2.handler = _classPrivateFieldGet(this, _end) // wait for any ending task to complete first
(_classPrivateFieldGet3 = _classPrivateFieldGet(this, _start)).handler ?? (_classPrivateFieldGet3.handler = _classPrivateFieldGet(this, _end) // wait for any ending task to complete first
? () => _classPrivateFieldGet(this, _end).promise.then(_classPrivateFieldGet(this, _handlers).start) : _classPrivateFieldGet(this, _handlers).start);

@@ -177,7 +182,7 @@ return _classPrivateMethodGet(this, _process, _process2).call(this, _classPrivateFieldGet(this, _start)).deferred;

end() {
var _classPrivateFieldGet3;
var _classPrivateFieldGet4;
_classPrivateFieldGet(this, _end) ?? _classPrivateFieldSet(this, _end, deferred({
readyState: 0
}));
(_classPrivateFieldGet3 = _classPrivateFieldGet(this, _end)).handler ?? (_classPrivateFieldGet3.handler = _classPrivateFieldGet(this, _start) // wait for any starting task to complete first
(_classPrivateFieldGet4 = _classPrivateFieldGet(this, _end)).handler ?? (_classPrivateFieldGet4.handler = _classPrivateFieldGet(this, _start) // wait for any starting task to complete first
? () => _classPrivateFieldGet(this, _start).promise.then(_classPrivateFieldGet(this, _handlers).end) : _classPrivateFieldGet(this, _handlers).end);

@@ -207,5 +212,5 @@ return _classPrivateMethodGet(this, _process, _process2).call(this, _classPrivateFieldGet(this, _end)).deferred;

close(abort) {
var _classPrivateFieldGet4;
var _classPrivateFieldGet5;
// when starting, state is updated afterwards
if ((_classPrivateFieldGet4 = _classPrivateFieldGet(this, _start)) !== null && _classPrivateFieldGet4 !== void 0 && _classPrivateFieldGet4.pending) _classPrivateFieldGet(this, _start).readyState = 3;
if ((_classPrivateFieldGet5 = _classPrivateFieldGet(this, _start)) !== null && _classPrivateFieldGet5 !== void 0 && _classPrivateFieldGet5.pending) _classPrivateFieldGet(this, _start).readyState = 3;
if (this.readyState < 3) this.readyState = 3;

@@ -229,6 +234,6 @@ if (abort) this.clear();

process(item) {
var _classPrivateFieldGet5;
var _classPrivateFieldGet6;
let task = _classPrivateMethodGet(this, _find, _find2).call(this, item);
if (task && !_classPrivateFieldGet(this, _start)) this.start();
(_classPrivateFieldGet5 = _classPrivateFieldGet(this, _start)) === null || _classPrivateFieldGet5 === void 0 ? void 0 : _classPrivateFieldGet5.promise.then(() => _classPrivateMethodGet(this, _process, _process2).call(this, task));
(_classPrivateFieldGet6 = _classPrivateFieldGet(this, _start)) === null || _classPrivateFieldGet6 === void 0 ? void 0 : _classPrivateFieldGet6.promise.then(() => _classPrivateMethodGet(this, _process, _process2).call(this, task));
return task === null || task === void 0 ? void 0 : task.deferred;

@@ -243,5 +248,5 @@ }

return yieldFor(() => {
var _classPrivateFieldGet6;
var _classPrivateFieldGet7;
callback === null || callback === void 0 ? void 0 : callback(_classPrivateFieldGet(this, _pending).size);
let starting = ((_classPrivateFieldGet6 = _classPrivateFieldGet(this, _start)) === null || _classPrivateFieldGet6 === void 0 ? void 0 : _classPrivateFieldGet6.pending) === true;
let starting = ((_classPrivateFieldGet7 = _classPrivateFieldGet(this, _start)) === null || _classPrivateFieldGet7 === void 0 ? void 0 : _classPrivateFieldGet7.pending) === true;
return !starting && !_classPrivateFieldGet(this, _pending).size;

@@ -332,4 +337,4 @@ }, {

yield* yieldFor(() => {
var _classPrivateFieldGet7;
if ((_classPrivateFieldGet7 = _classPrivateFieldGet(this, _start)) !== null && _classPrivateFieldGet7 !== void 0 && _classPrivateFieldGet7.pending) return false;
var _classPrivateFieldGet8;
if ((_classPrivateFieldGet8 = _classPrivateFieldGet(this, _start)) !== null && _classPrivateFieldGet8 !== void 0 && _classPrivateFieldGet8.pending) return false;
let queued,

@@ -336,0 +341,0 @@ pending = _classPrivateFieldGet(this, _pending).size;

@@ -1,10 +0,11 @@

function _classPrivateMethodInitSpec(obj, privateSet) { _checkPrivateRedeclaration(obj, privateSet); privateSet.add(obj); }
function _classPrivateFieldInitSpec(obj, privateMap, value) { _checkPrivateRedeclaration(obj, privateMap); privateMap.set(obj, value); }
function _checkPrivateRedeclaration(obj, privateCollection) { if (privateCollection.has(obj)) { throw new TypeError("Cannot initialize the same private elements twice on an object"); } }
function _classPrivateFieldGet(receiver, privateMap) { var descriptor = _classExtractFieldDescriptor(receiver, privateMap, "get"); return _classApplyDescriptorGet(receiver, descriptor); }
function _classApplyDescriptorGet(receiver, descriptor) { if (descriptor.get) { return descriptor.get.call(receiver); } return descriptor.value; }
function _classPrivateMethodGet(receiver, privateSet, fn) { if (!privateSet.has(receiver)) { throw new TypeError("attempted to get private field on non-instance"); } return fn; }
function _classPrivateFieldSet(receiver, privateMap, value) { var descriptor = _classExtractFieldDescriptor(receiver, privateMap, "set"); _classApplyDescriptorSet(receiver, descriptor, value); return value; }
function _classExtractFieldDescriptor(receiver, privateMap, action) { if (!privateMap.has(receiver)) { throw new TypeError("attempted to " + action + " private field on non-instance"); } return privateMap.get(receiver); }
function _classApplyDescriptorSet(receiver, descriptor, value) { if (descriptor.set) { descriptor.set.call(receiver, value); } else { if (!descriptor.writable) { throw new TypeError("attempted to set read only private field"); } descriptor.value = value; } }
function _classPrivateMethodInitSpec(e, a) { _checkPrivateRedeclaration(e, a), a.add(e); }
function _classPrivateFieldInitSpec(e, t, a) { _checkPrivateRedeclaration(e, t), t.set(e, a); }
function _checkPrivateRedeclaration(e, t) { if (t.has(e)) throw new TypeError("Cannot initialize the same private elements twice on an object"); }
function _classPrivateFieldGet2(e, t) { var r = _classPrivateFieldGet(t, e); return _classApplyDescriptorGet(e, r); }
function _classApplyDescriptorGet(e, t) { return t.get ? t.get.call(e) : t.value; }
function _classPrivateMethodGet(s, a, r) { return _assertClassBrand(a, s), r; }
function _classPrivateFieldSet(e, t, r) { var s = _classPrivateFieldGet(t, e); return _classApplyDescriptorSet(e, s, r), r; }
function _classPrivateFieldGet(s, a) { return s.get(_assertClassBrand(s, a)); }
function _assertClassBrand(e, t, n) { if ("function" == typeof e ? e === t : e.has(t)) return arguments.length < 3 ? t : n; throw new TypeError("Private element is not present on this object"); }
function _classApplyDescriptorSet(e, t, l) { if (t.set) t.set.call(e, l);else { if (!t.writable) throw new TypeError("attempted to set read only private field"); t.value = l; } }
import fs from 'fs';

@@ -133,3 +134,3 @@ import path from 'path';

let allowHeaders = req.headers['access-control-request-headers'] || '*';
let allowMethods = [...new Set(_classPrivateFieldGet(this, _routes).flatMap(route => (!route.match || route.match(req.url.pathname)) && route.methods || []))].join(', ');
let allowMethods = [...new Set(_classPrivateFieldGet2(this, _routes).flatMap(route => (!route.match || route.match(req.url.pathname)) && route.methods || []))].join(', ');
res.setHeader('Access-Control-Allow-Headers', allowHeaders);

@@ -156,4 +157,4 @@ res.setHeader('Access-Control-Allow-Methods', allowMethods);

this.on('connection', socket => {
let handleClose = () => _classPrivateFieldGet(this, _sockets).delete(socket);
_classPrivateFieldGet(this, _sockets).add(socket.on('close', handleClose));
let handleClose = () => _classPrivateFieldGet2(this, _sockets).delete(socket);
_classPrivateFieldGet2(this, _sockets).add(socket.on('close', handleClose));
});

@@ -170,3 +171,3 @@ }

var _super$address;
return ((_super$address = super.address()) === null || _super$address === void 0 ? void 0 : _super$address.port) ?? _classPrivateFieldGet(this, _defaultPort);
return ((_super$address = super.address()) === null || _super$address === void 0 ? void 0 : _super$address.port) ?? _classPrivateFieldGet2(this, _defaultPort);
}

@@ -186,3 +187,3 @@

// return a promise that resolves when the server is listening
listen(port = _classPrivateFieldGet(this, _defaultPort)) {
listen(port = _classPrivateFieldGet2(this, _defaultPort)) {
return new Promise((resolve, reject) => {

@@ -198,3 +199,3 @@ let handle = err => off() && err ? reject(err) : resolve(this);

return new Promise(resolve => {
_classPrivateFieldGet(this, _sockets).forEach(socket => socket.destroy());
_classPrivateFieldGet2(this, _sockets).forEach(socket => socket.destroy());
super.close(resolve);

@@ -206,2 +207,4 @@ });

// adds a route in the correct priority order
// set request routing and handling for pathnames and methods

@@ -264,4 +267,4 @@ route(method, pathname, handle) {

function _route2(route) {
let i = _classPrivateFieldGet(this, _routes).findIndex(r => r.priority >= route.priority);
_classPrivateFieldGet(this, _routes).splice(i, 0, route);
let i = _classPrivateFieldGet2(this, _routes).findIndex(r => r.priority >= route.priority);
_classPrivateFieldGet2(this, _routes).splice(i, 0, route);
return this;

@@ -285,3 +288,3 @@ }

return result ? handle(req, res, next) : next();
}(_classPrivateFieldGet(this, _routes));
}(_classPrivateFieldGet2(this, _routes));
} catch (error) {

@@ -288,0 +291,0 @@ var _req$headers$accept, _req$headers$content;

@@ -117,3 +117,4 @@ import logger from '@percy/logger';

name: options.name,
testCase: options.testCase
testCase: options.testCase,
labels: options.labels
}

@@ -120,0 +121,0 @@ }

{
"name": "@percy/core",
"version": "1.28.8-beta.4",
"version": "1.28.8-beta.6",
"license": "MIT",

@@ -46,7 +46,7 @@ "repository": {

"dependencies": {
"@percy/client": "1.28.8-beta.4",
"@percy/config": "1.28.8-beta.4",
"@percy/dom": "1.28.8-beta.4",
"@percy/logger": "1.28.8-beta.4",
"@percy/webdriver-utils": "1.28.8-beta.4",
"@percy/client": "1.28.8-beta.6",
"@percy/config": "1.28.8-beta.6",
"@percy/dom": "1.28.8-beta.6",
"@percy/logger": "1.28.8-beta.6",
"@percy/webdriver-utils": "1.28.8-beta.6",
"content-disposition": "^0.5.4",

@@ -56,3 +56,3 @@ "cross-spawn": "^7.0.3",

"fast-glob": "^3.2.11",
"micromatch": "^4.0.4",
"micromatch": "^4.0.6",
"mime-types": "^2.1.34",

@@ -62,6 +62,6 @@ "pako": "^2.1.0",

"rimraf": "^3.0.2",
"ws": "^8.0.0",
"ws": "^8.17.1",
"yaml": "^2.4.1"
},
"gitHead": "0ea30a56b97b5a5dab6ddc1282f71f1ecf07df2d"
"gitHead": "33ebd1aded619784a02e27cb26dbd344c7131ee9"
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc