@forsakringskassan/jest-config 29.8.0 → 30.0.0

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.
@@ -0,0 +1,13 @@
1
+ const defaultConfig = require("../jest-preset");
2
+
3
+ // Enable esm for Typescript files
4
+ defaultConfig.extensionsToTreatAsEsm = [".ts", ".tsx", ".mts"];
5
+ defaultConfig.transform = {
6
+ ["^.+\\.m?tsx?$"]: [
7
+ require.resolve("ts-jest"),
8
+ {
9
+ useESM: true,
10
+ },
11
+ ],
12
+ };
13
+ module.exports = defaultConfig;
package/jest.js CHANGED
@@ -6,6 +6,7 @@ const { spawn } = require("child_process");
6
6
  const pkgPath = path.dirname(require.resolve("jest/package.json"));
7
7
  const binary = path.join(pkgPath, "bin/jest.js");
8
8
 
9
+ /* eslint-disable-next-line sonarjs/no-os-command-from-path -- want to execute node from PATH */
9
10
  spawn("node", [binary, ...process.argv.slice(2)], {
10
11
  stdio: "inherit",
11
12
  }).on("exit", (code) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@forsakringskassan/jest-config",
3
- "version": "29.8.0",
3
+ "version": "30.0.0",
4
4
  "description": "Shareable jest configuration for npm packages",
5
5
  "keywords": [
6
6
  "jest"
@@ -20,7 +20,8 @@
20
20
  },
21
21
  "files": [
22
22
  "jest.js",
23
- "jest-preset.js"
23
+ "jest-preset.js",
24
+ "esm/jest-preset.js"
24
25
  ],
25
26
  "scripts": {
26
27
  "pretest": "node jest --version",
@@ -30,15 +31,15 @@
30
31
  "preset": "."
31
32
  },
32
33
  "dependencies": {
33
- "jest": "29.7.0",
34
+ "jest": "30.1.3",
34
35
  "jest-junit": "16.0.0",
35
- "jest-watch-typeahead": "2.2.2",
36
+ "jest-watch-typeahead": "3.0.1",
36
37
  "prettier-2": "npm:prettier@2.8.8",
37
- "ts-jest": "29.4.1"
38
+ "ts-jest": "29.4.4"
38
39
  },
39
40
  "engines": {
40
41
  "node": ">= 20",
41
42
  "npm": ">= 7"
42
43
  },
43
- "gitHead": "5b1f58cbd4900eeaebfa28ca9db9b22ce536b24e"
44
+ "gitHead": "74a1e88dc6e414e0a213c9d908cd711dd460a898"
44
45
  }