Socket
Socket
Sign inDemoInstall

create-jest-runner

Package Overview
Dependencies
Maintainers
8
Versions
24
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

create-jest-runner - npm Package Compare versions

Comparing version 0.12.1 to 0.12.2

33

build/createJestRunner.js

@@ -18,16 +18,2 @@ "use strict";

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 _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 determineSlowTestResult(test, result) {

@@ -57,12 +43,7 @@ // See: https://github.com/facebook/jest/blob/acd7c83c8365140f4ecf44a456ff7366ffa31fa2/packages/jest-runner/src/runTest.ts#L287

} = {}) {
var _globalConfig;
return class BaseTestRunner {
#globalConfig;
return _globalConfig = /*#__PURE__*/new WeakMap(), class BaseTestRunner {
constructor(globalConfig) {
_classPrivateFieldInitSpec(this, _globalConfig, {
writable: true,
value: void 0
});
_classPrivateFieldSet(this, _globalConfig, globalConfig);
this.#globalConfig = globalConfig;
}

@@ -85,3 +66,3 @@

config: test.context.config,
globalConfig: _classPrivateFieldGet(this, _globalConfig),
globalConfig: this.#globalConfig,
testPath: test.path,

@@ -105,3 +86,3 @@ rawModuleMap: watcher.isWatchMode() ? test.context.moduleMap.getRawModuleMap() : null,

exposedMethods: ['default'],
numWorkers: _classPrivateFieldGet(this, _globalConfig).maxWorkers,
numWorkers: this.#globalConfig.maxWorkers,
forkOptions: {

@@ -111,3 +92,3 @@ stdio: 'inherit'

});
const mutex = (0, _pLimit.default)(_classPrivateFieldGet(this, _globalConfig).maxWorkers);
const mutex = (0, _pLimit.default)(this.#globalConfig.maxWorkers);

@@ -122,3 +103,3 @@ const runTestInWorker = test => mutex(() => {

config: test.context.config,
globalConfig: _classPrivateFieldGet(this, _globalConfig),
globalConfig: this.#globalConfig,
testPath: test.path,

@@ -125,0 +106,0 @@ rawModuleMap: watcher.isWatchMode() ? test.context.moduleMap.getRawModuleMap() : null,

{
"name": "create-jest-runner",
"version": "0.12.1",
"version": "0.12.2",
"main": "build/index.js",

@@ -51,3 +51,3 @@ "types": "build/index.d.ts",

"@jest/test-result": "^29.0.0",
"@tsconfig/node12": "^1.0.9",
"@tsconfig/node14": "^1.0.3",
"@types/node": "^14.18.23",

@@ -54,0 +54,0 @@ "@typescript-eslint/eslint-plugin": "^5.14.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