Socket
Socket
Sign inDemoInstall

ts-jest

Package Overview
Dependencies
314
Maintainers
3
Versions
190
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 29.0.5 to 29.1.0

2

dist/cli/config/init.js

@@ -33,3 +33,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -36,0 +36,0 @@ if (y = 0, t) op = [op[0] & 2, t.value];

@@ -28,3 +28,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -31,0 +31,0 @@ if (y = 0, t) op = [op[0] & 2, t.value];

@@ -17,3 +17,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -20,0 +20,0 @@ if (y = 0, t) op = [op[0] & 2, t.value];

@@ -17,3 +17,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -20,0 +20,0 @@ if (y = 0, t) op = [op[0] & 2, t.value];

import type { Config } from '@jest/types';
declare type JestPathMapping = Config.InitialOptions['moduleNameMapper'];
type JestPathMapping = Config.InitialOptions['moduleNameMapper'];
export declare const pathsToModuleNameMapper: (mapping: import("typescript").MapLike<string[]>, { prefix, useESM }?: {

@@ -4,0 +4,0 @@ prefix?: string | undefined;

@@ -28,3 +28,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -94,3 +94,3 @@ if (y = 0, t) op = [op[0] & 2, t.value];

exports.CACHE_KEY_EL_SEPARATOR = '\x00';
var TsJestTransformer = /** @class */ (function () {
var TsJestTransformer = exports.TsJestTransformer = /** @class */ (function () {
function TsJestTransformer(tsJestConfig) {

@@ -312,6 +312,7 @@ this.tsJestConfig = tsJestConfig;

var _a;
var _b;
var configs = this._configsFor(transformOptions);
this._logger.debug({ fileName: filePath, transformOptions: transformOptions }, 'computing cache key for', filePath);
// we do not instrument, ensure it is false all the time
var _b = transformOptions.instrument, instrument = _b === void 0 ? false : _b;
var instrument = (_a = transformOptions.instrument, _a === void 0 ? false : _a);
var constructingCacheKeyElements = [

@@ -330,3 +331,3 @@ this._transformCfgStr,

var resolvedModuleNames = void 0;
if (((_a = this._depGraphs.get(filePath)) === null || _a === void 0 ? void 0 : _a.fileContent) === fileContent) {
if (((_b = this._depGraphs.get(filePath)) === null || _b === void 0 ? void 0 : _b.fileContent) === fileContent) {
this._logger.debug({ fileName: filePath, transformOptions: transformOptions }, 'getting resolved modules from disk caching or memory caching for', filePath);

@@ -384,2 +385,1 @@ // eslint-disable-next-line @typescript-eslint/no-non-null-assertion

}());
exports.TsJestTransformer = TsJestTransformer;

@@ -18,7 +18,7 @@ import type { TransformedSource, TransformOptions } from '@jest/transform';

}
export declare type TTypeScript = typeof _ts;
export type TTypeScript = typeof _ts;
/**
* Don't mark as internal because it is used in TsJestGlobalOptions which is an exposed type
*/
export declare type BabelConfig = _babel.TransformOptions;
export type BabelConfig = _babel.TransformOptions;
export interface AstTransformer<T = Record<string, unknown>> {

@@ -145,3 +145,3 @@ path: string;

}
export declare type TsJestTransformerOptions = TsJestGlobalOptions;
export type TsJestTransformerOptions = TsJestGlobalOptions;
export interface JestConfigWithTsJest extends Omit<Config.InitialOptions, 'transform'> {

@@ -152,4 +152,4 @@ transform?: {

}
export declare type TsJestPresets = Pick<JestConfigWithTsJest, 'extensionsToTreatAsEsm' | 'moduleFileExtensions' | 'transform' | 'testMatch'>;
export declare type StringMap = Map<string, string>;
export type TsJestPresets = Pick<JestConfigWithTsJest, 'extensionsToTreatAsEsm' | 'moduleFileExtensions' | 'transform' | 'testMatch'>;
export type StringMap = Map<string, string>;
export interface DepGraphInfo {

@@ -156,0 +156,0 @@ fileContent: string;

@@ -59,3 +59,3 @@ "use strict";

*/
var Importer = /** @class */ (function () {
var Importer = exports.Importer = /** @class */ (function () {
function Importer(_patches) {

@@ -193,3 +193,2 @@ if (_patches === void 0) { _patches = {}; }

}());
exports.Importer = Importer;
/**

@@ -196,0 +195,0 @@ * @internal

@@ -14,7 +14,6 @@ "use strict";

jest: createVersionChecker('jest', ">=29.0.0 <30" /* ExpectedVersions.Jest */),
typescript: createVersionChecker('typescript', ">=4.3 <5" /* ExpectedVersions.TypeScript */),
typescript: createVersionChecker('typescript', ">=4.3 <6" /* ExpectedVersions.TypeScript */),
babelJest: createVersionChecker('babel-jest', ">=29.0.0 <30" /* ExpectedVersions.BabelJest */),
babelCore: createVersionChecker('@babel/core', ">=7.0.0-beta.0 <8" /* ExpectedVersions.BabelCore */),
};
// eslint-disable-next-line no-redeclare
function checkVersion(name, expectedRange, action) {

@@ -21,0 +20,0 @@ if (action === void 0) { action = 'warn'; }

{
"name": "ts-jest",
"version": "29.0.5",
"version": "29.1.0",
"main": "dist/index.js",

@@ -68,3 +68,3 @@ "types": "dist/index.d.ts",

"jest": "^29.0.0",
"typescript": ">=4.3"
"typescript": ">=4.3 <6"
},

@@ -94,5 +94,5 @@ "peerDependenciesMeta": {

"@commitlint/cli": "17.x",
"@commitlint/config-angular": "^17.4.2",
"@jest/transform": "^29.1.2",
"@jest/types": "^29.1.2",
"@commitlint/config-angular": "^17.4.4",
"@jest/transform": "^29.5.0",
"@jest/types": "^29.5.0",
"@types/babel__core": "7.x",

@@ -106,4 +106,3 @@ "@types/cross-spawn": "latest",

"@types/micromatch": "4.x",
"@types/node": "18.11.18",
"@types/node-fetch": "^3.0.3",
"@types/node": "18.15.11",
"@types/react": "18.x",

@@ -114,9 +113,9 @@ "@types/rimraf": "^3.0.2",

"@types/yargs-parser": "21.x",
"@typescript-eslint/eslint-plugin": "^5.48.1",
"@typescript-eslint/parser": "^5.48.1",
"babel-jest": "^29.1.2",
"@typescript-eslint/eslint-plugin": "^5.57.0",
"@typescript-eslint/parser": "^5.57.0",
"babel-jest": "^29.5.0",
"conventional-changelog-cli": "2.x",
"cross-spawn": "latest",
"esbuild": "~0.16.17",
"eslint": "^8.31.0",
"esbuild": "~0.17.14",
"eslint": "^8.37.0",
"eslint-config-prettier": "latest",

@@ -130,15 +129,15 @@ "eslint-plugin-import": "latest",

"fs-extra": "11.x",
"glob": "^8.0.3",
"glob": "^9.3.2",
"glob-gitignore": "latest",
"husky": "4.x",
"jest": "^29.1.2",
"jest": "^29.5.0",
"jest-snapshot-serializer-raw": "^1.2.0",
"js-yaml": "latest",
"json-schema-to-typescript": "^11.0.2",
"json-schema-to-typescript": "^12.0.0",
"lint-staged": "latest",
"lodash.camelcase": "^4.3.0",
"lodash.set": "^4.3.2",
"node-fetch": "^3.3.0",
"prettier": "^2.8.2",
"typescript": "~4.8.4"
"node-fetch": "^3.3.1",
"prettier": "^2.8.7",
"typescript": "~5.0.2"
},

@@ -145,0 +144,0 @@ "lint-staged": {

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc