@zohodesk/unit-testing-framework 0.0.2-experimental → 0.0.4-experimental

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.
@@ -37,9 +37,20 @@ function getDefaultConfig(projectRoot) {
37
37
  // --------------- Environment ---------------
38
38
  testEnvironment: 'node',
39
39
  // --------------- Transform ---------------
40
- // ESM-native no transform needed for plain JS.
41
- // Consumer can add ts-jest / babel-jest as needed.
42
- transform: {},
40
+ // Use babel-jest to transform ESM (import/export) and JSX in
41
+ // consumer source & test files. Consumer's own babel config
42
+ // (babel.config.js / .babelrc) will be picked up automatically.
43
+ // If none exists, the fallback preset-env handles plain ESM → CJS.
44
+ transform: {
45
+ '\\.[jt]sx?$': ['babel-jest', {
46
+ presets: [['@babel/preset-env', {
47
+ targets: {
48
+ node: 'current'
49
+ }
50
+ }]]
51
+ }]
52
+ },
53
+ transformIgnorePatterns: ['/node_modules/'],
43
54
  // --------------- Coverage ---------------
44
55
  collectCoverage: false,
45
56
  coverageDirectory: _path.default.resolve(projectRoot, 'coverage'),
package/package.json CHANGED
@@ -1,39 +1,42 @@
1
1
  {
2
2
  "name": "@zohodesk/unit-testing-framework",
3
- "version": "0.0.2-experimental",
3
+ "version": "0.0.4-experimental",
4
4
  "description": "A modular Jest-based unit testing framework",
5
- "main": "./dist/index.js",
5
+ "main": "./build/index.js",
6
6
  "exports": {
7
- ".": "./dist/index.js",
8
- "./config": "./dist/src/config/config-loader.js",
9
- "./reporters": "./dist/src/reporters/reporter-handler.js",
10
- "./runner": "./dist/src/runner/jest-runner.js"
7
+ ".": "./build/index.js",
8
+ "./config": "./build/src/config/config-loader.js",
9
+ "./reporters": "./build/src/reporters/reporter-handler.js",
10
+ "./runner": "./build/src/runner/jest-runner.js"
11
11
  },
12
12
  "files": [
13
- "dist/"
13
+ "build/"
14
14
  ],
15
15
  "scripts": {
16
16
  "test": "node --experimental-vm-modules node_modules/.bin/jest",
17
17
  "lint": "eslint src/ index.js",
18
- "build": "babel src -d dist/src && babel index.js --out-file dist/index.js",
18
+ "build": "babel src -d build/src && babel index.js --out-file build/index.js",
19
19
  "prepublishOnly": "npm run build"
20
20
  },
21
21
  "keywords": [],
22
22
  "author": "",
23
23
  "license": "MIT",
24
24
  "dependencies": {
25
+ "@babel/core": "7.29.0",
26
+ "@babel/preset-env": "7.29.0",
25
27
  "@jest/core": "30.2.0",
26
28
  "@jest/types": "30.2.0",
29
+ "babel-jest": "30.2.0",
27
30
  "jest-environment-node": "30.2.0"
28
31
  },
29
32
  "peerDependencies": {
30
33
  "jest": "30.2.0"
31
34
  },
32
35
  "devDependencies": {
33
- "@babel/cli": "^7.28.6",
34
- "@babel/core": "^7.29.0",
35
- "@babel/plugin-transform-modules-commonjs": "^7.28.6",
36
- "@babel/preset-env": "^7.29.0",
36
+ "@babel/cli": "7.28.6",
37
+ "@babel/core": "7.29.0",
38
+ "@babel/plugin-transform-modules-commonjs": "7.28.6",
39
+ "@babel/preset-env": "7.29.0",
37
40
  "jest": "30.2.0"
38
41
  }
39
42
  }
File without changes
File without changes
File without changes
File without changes
File without changes