ts-jest 28.0.1 → 28.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/.ts-jest-digest CHANGED
@@ -1 +1 @@
1
- 8d08d902933d1a4cbd0bd1d101897a0e0238883e
1
+ 3ec913f3824bb3d8e0a11ca9d34fe5f15cb00d40
package/CHANGELOG.md CHANGED
@@ -1,3 +1,30 @@
1
+ ## [28.0.4](https://github.com/kulshekhar/ts-jest/compare/v28.0.3...v28.0.4) (2022-06-02)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * remove `@types/jest` from peer deps ([#3592](https://github.com/kulshekhar/ts-jest/issues/3592)) ([b66b656](https://github.com/kulshekhar/ts-jest/commit/b66b656e0f29eea9234a4d1e883c6d249437f03c))
7
+
8
+
9
+
10
+ ## [28.0.3](https://github.com/kulshekhar/ts-jest/compare/v28.0.2...v28.0.3) (2022-05-23)
11
+
12
+
13
+ ### Bug Fixes
14
+
15
+ * **security:** update version of `json5` ([#3528](https://github.com/kulshekhar/ts-jest/issues/3528)) ([b31f5ba](https://github.com/kulshekhar/ts-jest/commit/b31f5bab142466fd8b6157ec03eff7316584e51d))
16
+
17
+
18
+
19
+ ## [28.0.2](https://github.com/kulshekhar/ts-jest/compare/v28.0.1...v28.0.2) (2022-05-07)
20
+
21
+
22
+ ### Bug Fixes
23
+
24
+ * **transformers:** use `Array.sort` in hoisting transformer ([#3498](https://github.com/kulshekhar/ts-jest/issues/3498)) ([e400a6e](https://github.com/kulshekhar/ts-jest/commit/e400a6ec0e4706f606ae9b1e2897b0bb1cff6343)), closes [#3476](https://github.com/kulshekhar/ts-jest/issues/3476)
25
+
26
+
27
+
1
28
  ## [28.0.1](https://github.com/kulshekhar/ts-jest/compare/v28.0.0...v28.0.1) (2022-05-03)
2
29
 
3
30
 
@@ -42,6 +69,15 @@
42
69
 
43
70
 
44
71
 
72
+ ## [27.1.5](https://github.com/kulshekhar/ts-jest/compare/v27.1.3...v27.1.4) (2022-05-17)
73
+
74
+
75
+ ### Bug Fixes
76
+
77
+ * **transformers** use `Array.sort` in hoisting transformer ([#3498](https://github.com/kulshekhar/ts-jest/pull/3498)) ([e400a6e](https://github.com/kulshekhar/ts-jest/commit/e400a6ec0e4706f606ae9b1e2897b0bb1cff6343)), fixes [#3476](https://github.com/kulshekhar/ts-jest/issues/3476)
78
+
79
+
80
+
45
81
  ## [27.1.4](https://github.com/kulshekhar/ts-jest/compare/v27.1.3...v27.1.4) (2022-03-24)
46
82
 
47
83
 
@@ -825,7 +861,7 @@ import { mocked, createJestPreset, pathsToModuleNameMapper` } from 'ts-jest/util
825
861
  ### BREAKING CHANGES
826
862
 
827
863
  * Requires a minimum of TypeScript v3.8
828
- * Drop support for Node 8
864
+ * Drop support for Node 8
829
865
 
830
866
 
831
867
  <a name="25.5.1"></a>
package/README.md CHANGED
@@ -39,7 +39,7 @@ These instructions will get you setup to use `ts-jest` in your project. For more
39
39
  | **Prerequisites** | `npm i -D jest typescript` | `yarn add --dev jest typescript` |
40
40
  | **Installing** | `npm i -D ts-jest @types/jest` | `yarn add --dev ts-jest @types/jest` |
41
41
  | **Creating config** | `npx ts-jest config:init` | `yarn ts-jest config:init` |
42
- | **Running tests** | `npm t` or `npx jest` | `yarn test` or `yarn jest` |
42
+ | **Running tests** | `npm test` or `npx jest` | `yarn test` or `yarn jest` |
43
43
 
44
44
  ## Built With
45
45
 
@@ -50,21 +50,12 @@ function factory(_a) {
50
50
  if (statements.length <= 1) {
51
51
  return statements;
52
52
  }
53
- var pivot = statements[0];
54
- var leftPart = [];
55
- var rightPart = [];
56
- for (var i = 1; i < statements.length; i++) {
57
- var currentStatement = statements[i];
58
- if (isJestGlobalImport(currentStatement)) {
59
- leftPart.push(currentStatement);
60
- }
61
- else {
62
- isHoistableStatement(currentStatement) && !isHoistableStatement(pivot) && !isJestGlobalImport(pivot)
63
- ? leftPart.push(currentStatement)
64
- : rightPart.push(currentStatement);
65
- }
66
- }
67
- return sortStatements(leftPart).concat(pivot, sortStatements(rightPart));
53
+ return statements.sort(function (stmtA, stmtB) {
54
+ return isJestGlobalImport(stmtA) ||
55
+ (isHoistableStatement(stmtA) && !isHoistableStatement(stmtB) && !isJestGlobalImport(stmtB))
56
+ ? -1
57
+ : 1;
58
+ });
68
59
  };
69
60
  var createVisitor = function (ctx, _) {
70
61
  var visitor = function (node) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ts-jest",
3
- "version": "28.0.1",
3
+ "version": "28.0.4",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "bin": {
@@ -54,7 +54,7 @@
54
54
  "bs-logger": "0.x",
55
55
  "fast-json-stable-stringify": "2.x",
56
56
  "jest-util": "^28.0.0",
57
- "json5": "2.x",
57
+ "json5": "^2.2.1",
58
58
  "lodash.memoize": "4.x",
59
59
  "make-error": "1.x",
60
60
  "semver": "7.x",
@@ -62,7 +62,6 @@
62
62
  },
63
63
  "peerDependencies": {
64
64
  "@babel/core": ">=7.0.0-beta.0 <8",
65
- "@types/jest": "^27.0.0",
66
65
  "babel-jest": "^28.0.0",
67
66
  "jest": "^28.0.0",
68
67
  "typescript": ">=4.3"
@@ -71,9 +70,6 @@
71
70
  "@babel/core": {
72
71
  "optional": true
73
72
  },
74
- "@types/jest": {
75
- "optional": true
76
- },
77
73
  "babel-jest": {
78
74
  "optional": true
79
75
  },
@@ -89,8 +85,8 @@
89
85
  }
90
86
  },
91
87
  "devDependencies": {
92
- "@commitlint/cli": "16.x",
93
- "@commitlint/config-angular": "^16.0.0",
88
+ "@commitlint/cli": "17.x",
89
+ "@commitlint/config-angular": "^17.0.0",
94
90
  "@jest/transform": "^28.0.0",
95
91
  "@jest/types": "^28.0.0",
96
92
  "@types/babel__core": "7.x",
@@ -102,7 +98,7 @@
102
98
  "@types/lodash.memoize": "4.x",
103
99
  "@types/lodash.set": "4.x",
104
100
  "@types/micromatch": "4.x",
105
- "@types/node": "17.0.31",
101
+ "@types/node": "17.0.35",
106
102
  "@types/node-fetch": "^3.0.3",
107
103
  "@types/react": "18.x",
108
104
  "@types/rimraf": "^3.0.2",
@@ -113,7 +109,7 @@
113
109
  "@typescript-eslint/parser": "^5.3.0",
114
110
  "conventional-changelog-cli": "2.x",
115
111
  "cross-spawn": "latest",
116
- "esbuild": "~0.14.2",
112
+ "esbuild": "~0.14.42",
117
113
  "eslint": "^8.4.1",
118
114
  "eslint-config-prettier": "latest",
119
115
  "eslint-plugin-import": "latest",
@@ -123,7 +119,7 @@
123
119
  "eslint-plugin-prettier": "latest",
124
120
  "execa": "5.1.1",
125
121
  "fs-extra": "10.x",
126
- "glob": "^8.0.1",
122
+ "glob": "^8.0.3",
127
123
  "glob-gitignore": "latest",
128
124
  "husky": "4.x",
129
125
  "jest": "^28.0.0",
package/renovate.json ADDED
@@ -0,0 +1,68 @@
1
+ {
2
+ "extends": [
3
+ ":dependencyDashboard",
4
+ "group:babelMonorepo",
5
+ "group:commitlintMonorepo",
6
+ "group:docusaurusMonorepo",
7
+ ":prHourlyLimit2",
8
+ "workarounds:all"
9
+ ],
10
+ "timezone": "UTC",
11
+ "rangeStrategy": "bump",
12
+ "separateMajorMinor": true,
13
+ "prConcurrentLimit": 2,
14
+ "semanticCommits": "enabled",
15
+ "commitMessagePrefix": "build(deps):",
16
+ "ignorePaths": ["examples/react-app"],
17
+ "ignoreDeps": [
18
+ "@mdx-js/react",
19
+ "@types/react",
20
+ "execa",
21
+ "chalk",
22
+ "husky"
23
+ ],
24
+ "packageRules": [
25
+ {
26
+ "matchPaths": ["examples/**"],
27
+ "matchUpdateTypes": ["major"],
28
+ "enabled": false
29
+ },
30
+ {
31
+ "matchPaths": ["examples/react-app"],
32
+ "enabled": false
33
+ },
34
+ {
35
+ "matchPaths": ["package.json"],
36
+ "matchPackagePatterns": ["jest"],
37
+ "excludePackageNames": ["eslint-plugin-jest"],
38
+ "matchUpdateTypes": ["patch", "minor"],
39
+ "groupName": "Jest packages"
40
+ },
41
+ {
42
+ "extends": ["packages:eslint"],
43
+ "groupName": "ESLint packages"
44
+ },
45
+ {
46
+ "matchPackagePrefixes": ["esbuild"],
47
+ "groupName": "Esbuild packages"
48
+ },
49
+ {
50
+ "matchFiles": ["package.json"],
51
+ "matchDepTypes": ["dependencies", "optionalDependencies"],
52
+ "rangeStrategy": "in-range-only"
53
+ },
54
+ {
55
+ "matchPaths": ["e2e/**"],
56
+ "matchPackageNames": [
57
+ "react",
58
+ "react-intl"
59
+ ],
60
+ "groupName": "React e2e packages",
61
+ "enabled": true
62
+ },
63
+ {
64
+ "matchDepTypes": ["peerDependencies"],
65
+ "enabled": false
66
+ }
67
+ ]
68
+ }