Socket
Socket
Sign inDemoInstall

jest-each

Package Overview
Dependencies
Maintainers
1
Versions
144
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

jest-each - npm Package Compare versions

Comparing version 23.5.0 to 23.6.0

33

build/bind.js

@@ -57,4 +57,6 @@ 'use strict';

exports.default = cb =>
function() {
exports.default = function(cb) {
let supportsDone =
arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
return function() {
for (

@@ -79,3 +81,3 @@ var _len = arguments.length, args = Array(_len), _key = 0;

),
applyRestParams(row, test),
applyRestParams(supportsDone, row, test),
timeout

@@ -120,6 +122,11 @@ )

return table.forEach(row =>
cb(interpolate(title, row), applyObjectParams(row, test), timeout)
cb(
interpolate(title, row),
applyObjectParams(supportsDone, row, test),
timeout
)
);
};
};
};

@@ -183,10 +190,7 @@ const getPrettyIndexes = placeholders =>

const applyRestParams = (params, test) => {
if (params.length < test.length)
return done =>
test.apply(undefined, _toConsumableArray(params).concat([done]));
const applyRestParams = (supportsDone, params, test) =>
supportsDone && params.length < test.length
? done => test.apply(undefined, _toConsumableArray(params).concat([done]))
: () => test.apply(undefined, _toConsumableArray(params));
return () => test.apply(undefined, _toConsumableArray(params));
};
const getHeadingKeys = headings => headings.replace(/\s/g, '').split('|');

@@ -224,8 +228,5 @@

const applyObjectParams = (obj, test) => {
if (test.length > 1) return done => test(obj, done);
const applyObjectParams = (supportsDone, obj, test) =>
supportsDone && test.length > 1 ? done => test(obj, done) : () => test(obj);
return () => test(obj);
};
const pluralize = (word, count) => word + (count === 1 ? '' : 's');

@@ -232,0 +233,0 @@

@@ -73,23 +73,22 @@ 'use strict';

const describe = (title, suite, timeout) =>
(0, (_bind || _load_bind()).default)(g.describe).apply(undefined, args)(
title,
suite,
timeout
);
describe.skip = (0, (_bind || _load_bind()).default)(g.describe.skip).apply(
undefined,
args
);
describe.only = (0, (_bind || _load_bind()).default)(g.describe.only).apply(
undefined,
args
);
const fdescribe = (0, (_bind || _load_bind()).default)(g.fdescribe).apply(
undefined,
args
);
const xdescribe = (0, (_bind || _load_bind()).default)(g.xdescribe).apply(
undefined,
args
);
(0, (_bind || _load_bind()).default)(g.describe, false).apply(
undefined,
args
)(title, suite, timeout);
describe.skip = (0, (_bind || _load_bind()).default)(
g.describe.skip,
false
).apply(undefined, args);
describe.only = (0, (_bind || _load_bind()).default)(
g.describe.only,
false
).apply(undefined, args);
const fdescribe = (0, (_bind || _load_bind()).default)(
g.fdescribe,
false
).apply(undefined, args);
const xdescribe = (0, (_bind || _load_bind()).default)(
g.xdescribe,
false
).apply(undefined, args);

@@ -96,0 +95,0 @@ return {

{
"name": "jest-each",
"version": "23.5.0",
"version": "23.6.0",
"description": "Parameterised tests for Jest",

@@ -20,4 +20,4 @@ "main": "build/index.js",

"chalk": "^2.0.1",
"pretty-format": "^23.5.0"
"pretty-format": "^23.6.0"
}
}
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